Skip to content

Commit e5d6763

Browse files
authored
fix: update sapphire dependencies (#794)
* fix: update sapphire dependencies * chore: i must enjoy torturing myself * chore: tagging release w.t.f. * chore: this bug has driven lots of coders completely mad. you won't believe how it ended up being fixed * chore: fix tpyo
1 parent 2e4b51c commit e5d6763

16 files changed

+606
-689
lines changed

.github/workflows/continuous-integration.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ jobs:
1313

1414
docs:
1515
name: Docgen
16-
if: github.event_name == 'pull_request'
16+
if: github.event_name == 'pull_request' && false
1717
uses: sapphiredev/.github/.github/workflows/reusable-yarn-job.yml@main
1818
with:
1919
script-name: docs

.github/workflows/documentation.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ on:
1010
jobs:
1111
docgen:
1212
uses: sapphiredev/.github/.github/workflows/reusable-documentation.yml@main
13+
if: false
1314
with:
1415
project-name: framework
1516
secrets:

package.json

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -34,14 +34,14 @@
3434
},
3535
"dependencies": {
3636
"@discordjs/builders": "^1.9.0",
37-
"@sapphire/discord-utilities": "^3.4.1",
38-
"@sapphire/discord.js-utilities": "^7.3.0",
39-
"@sapphire/lexure": "^1.1.7",
37+
"@sapphire/discord-utilities": "^3.4.2",
38+
"@sapphire/discord.js-utilities": "^7.3.1",
39+
"@sapphire/lexure": "^1.1.9",
4040
"@sapphire/pieces": "^4.3.1",
41-
"@sapphire/ratelimits": "^2.4.9",
42-
"@sapphire/result": "^2.6.6",
43-
"@sapphire/stopwatch": "^1.5.2",
44-
"@sapphire/utilities": "^3.17.0"
41+
"@sapphire/ratelimits": "^2.4.10",
42+
"@sapphire/result": "^2.7.1",
43+
"@sapphire/stopwatch": "^1.5.3",
44+
"@sapphire/utilities": "^3.18.0"
4545
},
4646
"devDependencies": {
4747
"@commitlint/cli": "^19.5.0",
@@ -53,11 +53,11 @@
5353
"@sapphire/node-utilities": "^1.0.2",
5454
"@sapphire/prettier-config": "^2.0.0",
5555
"@sapphire/ts-config": "^5.0.1",
56-
"@types/node": "^20.17.1",
57-
"@types/ws": "^8.5.12",
56+
"@types/node": "^20.17.5",
57+
"@types/ws": "^8.5.13",
5858
"@typescript-eslint/eslint-plugin": "^7.18.0",
5959
"@typescript-eslint/parser": "^7.18.0",
60-
"@vitest/coverage-v8": "^2.1.3",
60+
"@vitest/coverage-v8": "^2.1.4",
6161
"concurrently": "^9.0.1",
6262
"cz-conventional-changelog": "^3.3.0",
6363
"discord.js": "^14.16.3",
@@ -70,12 +70,12 @@
7070
"gen-esm-wrapper": "^1.1.3",
7171
"lint-staged": "^15.2.10",
7272
"prettier": "^3.3.3",
73-
"tsup": "^8.3.0",
74-
"typedoc": "^0.26.10",
73+
"tsup": "^8.3.5",
74+
"typedoc": "^0.26.11",
7575
"typedoc-json-parser": "^10.1.6",
7676
"typescript": "~5.4.5",
7777
"vite": "^5.4.10",
78-
"vitest": "^2.1.3"
78+
"vitest": "^2.1.4"
7979
},
8080
"repository": {
8181
"type": "git",

src/index.ts

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -41,17 +41,17 @@ const ApplicationCommandRegistries = {
4141
export {
4242
AliasPiece,
4343
AliasStore,
44+
container,
4445
LoaderError,
4546
MissingExportsError,
4647
Piece,
4748
Store,
4849
StoreRegistry,
49-
container,
5050
type AliasPieceJSON,
5151
type AliasPieceOptions,
5252
type Container,
5353
type LoaderPieceContext,
54-
type PieceContext, // eslint-disable-line deprecation/deprecation
54+
type PieceContext,
5555
type PieceJSON,
5656
type PieceLocationJSON,
5757
type PieceOf,
@@ -66,7 +66,6 @@ export {
6666
} from '@sapphire/pieces';
6767
export * from '@sapphire/result';
6868
export type { Awaitable } from '@sapphire/utilities';
69-
export * from './lib/SapphireClient';
7069
export * from './lib/errors/ArgumentError';
7170
export * from './lib/errors/Identifiers';
7271
export * from './lib/errors/PreconditionError';
@@ -79,6 +78,7 @@ export * as PreconditionResolvers from './lib/precondition-resolvers/index';
7978
export type { EmojiObject } from './lib/resolvers/emoji';
8079
export * as Resolvers from './lib/resolvers/index';
8180
export type { MessageResolverOptions } from './lib/resolvers/message';
81+
export * from './lib/SapphireClient';
8282
export * from './lib/structures/Argument';
8383
export * from './lib/structures/ArgumentStore';
8484
export * from './lib/structures/Command';
@@ -100,14 +100,14 @@ export {
100100
} from './lib/utils/application-commands/ApplicationCommandRegistry';
101101
export * from './lib/utils/logger/ILogger';
102102
export * from './lib/utils/logger/Logger';
103-
export * from './lib/utils/preconditions/IPreconditionContainer';
104-
export * from './lib/utils/preconditions/PreconditionContainerArray';
105-
export * from './lib/utils/preconditions/PreconditionContainerSingle';
106103
export * from './lib/utils/preconditions/conditions/IPreconditionCondition';
107104
export * from './lib/utils/preconditions/conditions/PreconditionConditionAnd';
108105
export * from './lib/utils/preconditions/conditions/PreconditionConditionOr';
109106
export * from './lib/utils/preconditions/containers/ClientPermissionsPrecondition';
110107
export * from './lib/utils/preconditions/containers/UserPermissionsPrecondition';
108+
export * from './lib/utils/preconditions/IPreconditionContainer';
109+
export * from './lib/utils/preconditions/PreconditionContainerArray';
110+
export * from './lib/utils/preconditions/PreconditionContainerSingle';
111111
export { ApplicationCommandRegistries };
112112

113113
/* eslint-disable deprecation/deprecation */

src/lib/types/CommandTypes.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import { AliasPiece, type AliasPieceJSON } from '@sapphire/pieces';
2-
import { type NonNullObject, type Nullish } from '@sapphire/utilities';
2+
import type { Nullish } from '@sapphire/utilities';
33
import {
44
ChannelType,
55
ChatInputCommandInteraction,
@@ -16,7 +16,7 @@ import { BucketScope, CommandOptionsRunTypeEnum } from './Enums';
1616

1717
export type DetailedDescriptionCommand = string | DetailedDescriptionCommandObject;
1818

19-
export interface DetailedDescriptionCommandObject extends NonNullObject {}
19+
export interface DetailedDescriptionCommandObject {}
2020

2121
/**
2222
* The allowed values for {@link CommandOptions.runIn}.

src/preconditions/DMOnly.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,6 @@ export class CorePrecondition extends AllFlowsPrecondition {
1818

1919
private makeSharedError(): AllFlowsPrecondition.Result {
2020
return this.error({
21-
// eslint-disable-next-line deprecation/deprecation
2221
identifier: Identifiers.PreconditionDMOnly,
2322
message: 'You cannot run this command outside DMs.'
2423
});

src/preconditions/GuildNewsOnly.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,6 @@ export class CorePrecondition extends AllFlowsPrecondition {
2424

2525
private makeSharedError(): AllFlowsPrecondition.Result {
2626
return this.error({
27-
// eslint-disable-next-line deprecation/deprecation
2827
identifier: Identifiers.PreconditionGuildNewsOnly,
2928
message: 'You can only run this command in server announcement channels.'
3029
});

src/preconditions/GuildNewsThreadOnly.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,6 @@ export class CorePrecondition extends AllFlowsPrecondition {
2020

2121
private makeSharedError(): AllFlowsPrecondition.Result {
2222
return this.error({
23-
// eslint-disable-next-line deprecation/deprecation
2423
identifier: Identifiers.PreconditionGuildNewsThreadOnly,
2524
message: 'You can only run this command in server announcement thread channels.'
2625
});

src/preconditions/GuildOnly.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,6 @@ export class CorePrecondition extends AllFlowsPrecondition {
1818

1919
private makeSharedError(): AllFlowsPrecondition.Result {
2020
return this.error({
21-
// eslint-disable-next-line deprecation/deprecation
2221
identifier: Identifiers.PreconditionGuildOnly,
2322
message: 'You cannot run this command in DMs.'
2423
});

src/preconditions/GuildPrivateThreadOnly.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,6 @@ export class CorePrecondition extends AllFlowsPrecondition {
2020

2121
private makeSharedError(): AllFlowsPrecondition.Result {
2222
return this.error({
23-
// eslint-disable-next-line deprecation/deprecation
2423
identifier: Identifiers.PreconditionGuildPrivateThreadOnly,
2524
message: 'You can only run this command in private server thread channels.'
2625
});

src/preconditions/GuildPublicThreadOnly.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,6 @@ export class CorePrecondition extends AllFlowsPrecondition {
2020

2121
private makeSharedError(): AllFlowsPrecondition.Result {
2222
return this.error({
23-
// eslint-disable-next-line deprecation/deprecation
2423
identifier: Identifiers.PreconditionGuildPublicThreadOnly,
2524
message: 'You can only run this command in public server thread channels.'
2625
});

src/preconditions/GuildTextOnly.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,6 @@ export class CorePrecondition extends AllFlowsPrecondition {
2222

2323
private makeSharedError(): AllFlowsPrecondition.Result {
2424
return this.error({
25-
// eslint-disable-next-line deprecation/deprecation
2625
identifier: Identifiers.PreconditionGuildTextOnly,
2726
message: 'You can only run this command in server text channels.'
2827
});

src/preconditions/GuildThreadOnly.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,6 @@ export class CorePrecondition extends AllFlowsPrecondition {
2020

2121
private makeSharedError(): AllFlowsPrecondition.Result {
2222
return this.error({
23-
// eslint-disable-next-line deprecation/deprecation
2423
identifier: Identifiers.PreconditionThreadOnly,
2524
message: 'You can only run this command in server thread channels.'
2625
});

src/preconditions/GuildVoiceOnly.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,6 @@ export class CorePrecondition extends AllFlowsPrecondition {
2121

2222
private makeSharedError(): AllFlowsPrecondition.Result {
2323
return this.error({
24-
// eslint-disable-next-line deprecation/deprecation
2524
identifier: Identifiers.PreconditionGuildVoiceOnly,
2625
message: 'You can only run this command in server voice channels.'
2726
});

tests/resolvers/emoji.test.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ describe('Emoji resolver tests', () => {
66
test('GIVEN an unicode emoji THEN returns emojiObject', () => {
77
const resolvedEmoji = resolveEmoji('😄');
88
expect(resolvedEmoji.isOk()).toBe(true);
9-
expect(resolvedEmoji.unwrapErr).toThrowError();
9+
expect(() => resolvedEmoji.unwrapErr()).toThrowError();
1010
expect(resolvedEmoji.unwrap()).toMatchObject({ id: null, name: '😄' });
1111
});
1212
test('GIVEN a string emoji THEN returns ArgumentEmojiError', () => {
@@ -24,13 +24,13 @@ describe('Emoji resolver tests', () => {
2424
test('GIVEN a string custom emoji THEN returns emojiObject', () => {
2525
const resolvedEmoji = resolveEmoji('<:custom:737141877803057244>');
2626
expect(resolvedEmoji.isOk()).toBe(true);
27-
expect(resolvedEmoji.unwrapErr).toThrowError();
27+
expect(() => resolvedEmoji.unwrapErr()).toThrowError();
2828
expect(resolvedEmoji.unwrap()).toMatchObject({ id: '737141877803057244', name: 'custom' });
2929
});
3030
test('GIVEN a string custom animated emoji THEN returns emojiObject', () => {
3131
const resolvedEmoji = resolveEmoji('<a:custom:737141877803057244>');
3232
expect(resolvedEmoji.isOk()).toBe(true);
33-
expect(resolvedEmoji.unwrapErr).toThrowError();
33+
expect(() => resolvedEmoji.unwrapErr()).toThrowError();
3434
expect(resolvedEmoji.unwrap()).toMatchObject({ animated: true, id: '737141877803057244', name: 'custom' });
3535
});
3636
});

0 commit comments

Comments
 (0)