refactor(controllers): separate controllers into different files (#657)

* refactor(controllers): separate controller into files

* add CHANNEL_UPDATE

* guilds

* interactions

* members

* messages

* finally

* done

* fix ci

* fixes
This commit is contained in:
ayntee
2021-03-11 20:38:27 +04:00
committed by GitHub
parent 359a775715
commit aaed064709
62 changed files with 1157 additions and 1060 deletions
+1 -1
View File
@@ -23,7 +23,7 @@ import {
botHasPermission,
calculateBits,
} from "../../util/permissions.ts";
import { cacheHandlers } from "../controllers/cache.ts";
import { cacheHandlers } from "../../cache.ts";
import { structures } from "../structures/mod.ts";
/** Checks if a channel overwrite for a user id or a role id has permission in this channel */
+1 -1
View File
@@ -44,7 +44,7 @@ import {
urlToBase64,
} from "../../util/utils.ts";
import { requestAllMembers } from "../../ws/shard_manager.ts";
import { cacheHandlers } from "../controllers/cache.ts";
import { cacheHandlers } from "../../cache.ts";
import { Guild, Member, structures } from "../structures/mod.ts";
/** Create a new guild. Returns a guild object on success. Fires a Guild Create Gateway event. This endpoint can be used only by bots in less than 10 guilds. */
+1 -1
View File
@@ -17,7 +17,7 @@ import {
highestRole,
} from "../../util/permissions.ts";
import { formatImageURL, urlToBase64 } from "../../util/utils.ts";
import { cacheHandlers } from "../controllers/cache.ts";
import { cacheHandlers } from "../../cache.ts";
import { Member, structures } from "../structures/mod.ts";
import { sendMessage } from "./channel.ts";
+1 -1
View File
@@ -11,7 +11,7 @@ import { Collection } from "../../util/collection.ts";
import { endpoints } from "../../util/constants.ts";
import { botHasChannelPermissions } from "../../util/permissions.ts";
import { delay } from "../../util/utils.ts";
import { cacheHandlers } from "../controllers/cache.ts";
import { cacheHandlers } from "../../cache.ts";
import { Message, structures } from "../structures/mod.ts";
/** Delete a message with the channel id and message id only. */