Skip to content

Commit

Permalink
more dependency shenanigans
Browse files Browse the repository at this point in the history
  • Loading branch information
DonovanDMC committed Oct 26, 2024
1 parent d95ae54 commit 9ca907f
Show file tree
Hide file tree
Showing 6 changed files with 312 additions and 742 deletions.
6 changes: 6 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,3 +16,9 @@ updates:
ignore:
- dependency-name: "@types/node"
update-types: ["version-update:semver-major"]
- dependency-name: "@typescript-eslint/parser"
update-types: ["version-update:semver-major"]
- dependency-name: "@typescript-eslint/eslint-plugin"
update-types: ["version-update:semver-major"]
- dependency-name: "typedoc-plugin-extras"
update-types: ["version-update:semver-minor"]
2 changes: 1 addition & 1 deletion lib/gateway/events.ts
Original file line number Diff line number Diff line change
Expand Up @@ -850,7 +850,7 @@ export async function THREAD_MEMBERS_UPDATE(data: DispatchEventMap["THREAD_MEMBE
}
for (const [index, { userID }] of removedMembers.entries()) {
const memberIndex = thread.members.findIndex(m => m.userID === userID);
if (memberIndex >= 0) {
if (memberIndex !== -1) {
removedMembers[index] = thread.members[memberIndex];
thread.members.splice(memberIndex, 1);
}
Expand Down
4 changes: 2 additions & 2 deletions lib/routes/Channels.ts
Original file line number Diff line number Diff line change
Expand Up @@ -746,7 +746,7 @@ export default class Channels {
async *[Symbol.asyncIterator](): AsyncGenerator<Array<Message<T>>> {
loop: while (it.limit > 0) {
const messages = await self.getMessages<T>(channelID, {
limit: it.limit >= 100 ? 100 : it.limit,
limit: Math.min(it.limit, 100),
[chosenOption]: it.lastMessage
});

Expand Down Expand Up @@ -950,7 +950,7 @@ export default class Channels {
let reactions: Array<User> = [];
while (reactions.length < limit) {
const limitLeft = limit - reactions.length;
const limitToFetch = limitLeft <= 100 ? limitLeft : 100;
const limitToFetch = Math.min(limitLeft, 100);
this._manager.client.emit("debug", `Getting ${limitLeft} more ${emoji} reactions for message ${messageID} on ${channelID}: ${after ?? ""}`);
const reactionsChunk = await _getReactions({
after,
Expand Down
2 changes: 1 addition & 1 deletion lib/routes/Guilds.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1303,7 +1303,7 @@ export default class Guilds {
let bans: Array<Ban> = [];
while (bans.length < limit) {
const limitLeft = limit - bans.length;
const limitToFetch = limitLeft <= 1000 ? limitLeft : 1000;
const limitToFetch = Math.min(limitLeft, 1000);
this._manager.client.emit("debug", `Getting ${limitLeft} more ban${limitLeft === 1 ? "" : "s"} for ${guildID}: ${optionValue ?? ""}`);
const bansChunk = await _getBans({
limit: limitToFetch,
Expand Down
14 changes: 7 additions & 7 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -42,31 +42,31 @@
},
"homepage": "https://github.com/OceanicJS/Oceanic#readme",
"devDependencies": {
"@favware/npm-deprecate": "^1.0.7",
"@mxssfd/typedoc-theme": "^1.1.7",
"@favware/npm-deprecate": "^2.0.0",
"@mxssfd/typedoc-theme": "^1.1.3",
"@types/node": "^18.19.59",
"@types/pako": "^2.0.3",
"@types/ws": "^8.5.12",
"@typescript-eslint/eslint-plugin": "^7.18.0",
"@typescript-eslint/parser": "^6.21.0",
"@typescript-eslint/parser": "^7.18.0",
"erlpack": "^0.1.4",
"eslint": "^8.57.1",
"eslint-plugin-import": "^2.31.0",
"eslint-plugin-import-newlines": "^1.4.0",
"eslint-plugin-jsdoc": "^50.4.3",
"eslint-plugin-json": "^4.0.1",
"eslint-plugin-prefer-arrow": "^1.2.3",
"eslint-plugin-unicorn": "^55.0.0",
"eslint-plugin-unicorn": "^56.0.0",
"eslint-plugin-unused-imports": "^4.1.4",
"fzstd": "^0.1.1",
"pako": "^2.1.0",
"rimraf": "^6.0.1",
"typedoc": "0.26.6",
"typedoc-plugin-extras": "3.0.0",
"typedoc": "~0.25.13",
"typedoc-plugin-extras": "~3.0.0",
"typedoc-plugin-mdn-links": "^3.3.4",
"typedoc-plugin-merge-modules": "^5.1.0",
"typescript": "~5.4.5",
"undici-types": "^6.20.0",
"undici-types": "^5.28.4",
"zlib-sync": "^0.1.9"
},
"dependencies": {
Expand Down
Loading

0 comments on commit 9ca907f

Please sign in to comment.