mirror of
https://github.com/spacebarchat/server.git
synced 2026-10-22 17:32:30 +00:00
🎨 Convert id bigint to string
This commit is contained in:
1 parent
79c4fd55fc
commit
7685e19835
59 files changed
+493
-495
No files matched your search
@@ -121,7 +121,7 @@ export class Permissions extends BitField {
|
||||
guild,
|
||||
channel,
|
||||
}: {
|
||||
user: { id: bigint; roles: bigint[] };
|
||||
user: { id: string; roles: string[] };
|
||||
guild: { roles: Role[] };
|
||||
channel?: {
|
||||
overwrites?: ChannelPermissionOverwrite[];
|
||||
@@ -144,9 +144,9 @@ export class Permissions extends BitField {
|
||||
}
|
||||
|
||||
export async function getPermission(
|
||||
user_id: bigint,
|
||||
guild_id: bigint,
|
||||
channel_id?: bigint,
|
||||
user_id: string,
|
||||
guild_id: string,
|
||||
channel_id?: string,
|
||||
cache?: { channel?: ChannelDocument | null; member?: MemberDocument | null }
|
||||
) {
|
||||
var { channel, member } = cache || {};
|
||||
|
||||
@@ -87,7 +87,7 @@ export class Snowflake {
|
||||
var worker = Snowflake.workerId << 17n;
|
||||
var process = Snowflake.processId << 12n;
|
||||
var increment = Snowflake.INCREMENT++;
|
||||
return time | worker | process | increment;
|
||||
return (time | worker | process | increment).toString();
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in new issue
Block a user