delete method

Future<void> delete({
  1. String? reason,
})

Delete this invite

Invite invite = guild.invites.cache.get('invite_code');
invite.delete(reason: 'reason');

Implementation

Future<void> delete ({ String? reason }) async {
  await ioc.use<DiscordApiHttpService>()
    .destroy(url: '/invites/$_code')
    .auditLog(reason)
    .build();
}