Skip to content

Commit

Permalink
handler -> events
Browse files Browse the repository at this point in the history
  • Loading branch information
Leref committed Jun 4, 2024
1 parent 0b27d50 commit 23d885c
Show file tree
Hide file tree
Showing 97 changed files with 12 additions and 12 deletions.
6 changes: 3 additions & 3 deletions src/classes/AoiBase.js
Original file line number Diff line number Diff line change
Expand Up @@ -103,9 +103,9 @@ class BaseClient extends Client {
Object.defineProperty(this, "statuses", { value: new Group() });

this.on("ready", async () => {
await require("../handler/NonIntents/ready.js")(this);
await require("../handler/status.js")(this.statuses, this);
await require("../handler/AoiStart.js")(this);
await require("../events/NonIntents/ready.js")(this);
await require("../events/status.js")(this.statuses, this);
await require("../events/AoiStart.js")(this);
});
this.login(options.token);
}
Expand Down
2 changes: 1 addition & 1 deletion src/classes/ClientShard.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ class ClientShard extends ShardingManager {

onShardCreate() {
this.on("shardCreate", async (shard) =>
require("../shardhandler/shardCreate.js")(shard, this.cmd),
require("../sharding/shardCreate.js")(shard, this.cmd),
);
}
}
Expand Down
2 changes: 1 addition & 1 deletion src/classes/CustomEvent.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
const EventExecuter = require("../handler/eventExecuter.js");
const EventExecuter = require("../events/eventExecuter.js");
const {EventEmitter} = require("events");
const { Group : Collection } = require( "@akarui/structures" );

Expand Down
2 changes: 1 addition & 1 deletion src/classes/Util.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
const Constants = require("../utils/Constants.js");
const Discord = require("discord.js");
const parsers = require("../handler/parsers.js");
const parsers = require("../events/parsers.js");

class Util {
static constants = Constants;
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
2 changes: 1 addition & 1 deletion src/functions/interaction/createApplicationCommand.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
const { ApplicationCommandType } = require("discord.js");
const { SlashTypes } = require("../../utils/InteractionConstants.js");
const parser = require("../../handler/slashCommandOptionsParser");
const parser = require("../../events/slashCommandOptionsParser");

module.exports = async (d) => {
const data = d.util.aoiFunc(d);
Expand Down
2 changes: 1 addition & 1 deletion src/functions/interaction/modifyApplicationCommand.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
const {SlashOptionsParser} = require('../../handler/parsers.js')
const {SlashOptionsParser} = require('../../events/parsers.js')
module.exports = async d => {
const data = d.util.aoiFunc(d);
if (data.err) return d.error(data.err);
Expand Down
2 changes: 1 addition & 1 deletion src/functions/util/formatDate.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
const formatDate = require("../../handler/FormatDate");
const formatDate = require("../../events/FormatDate");

module.exports = (d) => {
const code = d.command.code,
Expand Down
2 changes: 1 addition & 1 deletion src/index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { Group, LimitGroup, SuperSet } from "@akarui/structures";
import { Group as Collection } from "@akarui/structures";
import { AllEvents } from "./utils/Constants";
import { Constants } from "./utils/Constants";
import { parsers } from "./handler/parsers";
import { parsers } from "./events/parsers";

declare module "aoi.js" {
import { EventEmitter } from "events";
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
2 changes: 1 addition & 1 deletion src/utils/helpers/functions.js
Original file line number Diff line number Diff line change
Expand Up @@ -282,7 +282,7 @@ module.exports = {
timeoutData.__timeoutName__ = name;
timeoutData.__id__ = Math.floor(Math.random() * 999999);

require("../../handler/Custom/timeout.js")(d, duration, timeoutData, false);
require("../../events/Custom/timeout.js")(d, duration, timeoutData, false);
return timeoutData.__id__;
},
CreateObjectAST(parser) {
Expand Down
2 changes: 1 addition & 1 deletion src/utils/helpers/prototypes.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
const fs = require("fs");
const searchIndexes = require("../../handler/searchIndexes");
const searchIndexes = require("../../events/searchIndexes");

String.prototype.replaceLast = function (find, replace) {
const index = this.lastIndexOf(find);
Expand Down

0 comments on commit 23d885c

Please sign in to comment.