Skip to content

Commit

Permalink
fix(GuildAuditLogsEntry): replace OverwriteType with AuditLogOptionsT…
Browse files Browse the repository at this point in the history
…ype (#8345)
  • Loading branch information
thehairy committed Jul 24, 2022
1 parent 6a2d0d8 commit 58c1b51
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions packages/discord.js/src/structures/GuildAuditLogsEntry.js
@@ -1,7 +1,7 @@
'use strict';

const { DiscordSnowflake } = require('@sapphire/snowflake');
const { OverwriteType, AuditLogEvent } = require('discord-api-types/v10');
const { AuditLogOptionsType, AuditLogEvent } = require('discord-api-types/v10');
const { GuildScheduledEvent } = require('./GuildScheduledEvent');
const Integration = require('./Integration');
const Invite = require('./Invite');
Expand Down Expand Up @@ -189,18 +189,18 @@ class GuildAuditLogsEntry {
case AuditLogEvent.ChannelOverwriteUpdate:
case AuditLogEvent.ChannelOverwriteDelete:
switch (data.options.type) {
case OverwriteType.Role:
case AuditLogOptionsType.Role:
this.extra = guild.roles.cache.get(data.options.id) ?? {
id: data.options.id,
name: data.options.role_name,
type: OverwriteType.Role,
type: AuditLogOptionsType.Role,
};
break;

case OverwriteType.Member:
case AuditLogOptionsType.Member:
this.extra = guild.members.cache.get(data.options.id) ?? {
id: data.options.id,
type: OverwriteType.Member,
type: AuditLogOptionsType.Member,
};
break;

Expand Down

1 comment on commit 58c1b51

@vercel
Copy link

@vercel vercel bot commented on 58c1b51 Jul 24, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.