onCustomerUnbanned
Last updated
Last updated
exports['sd-shops']:registerServerHook('onCustomerUnbanned', function(data)
-- Log unban
print(('[UNBAN] %s unbanned %s from %s (Was banned %d days)'):format(
data.unbannedBy, data.customerName, data.shopName, data.banDuration
))
-- Update MDT/admin system
exports['your-mdt']:RemoveBanRecord({
type = 'shop-ban',
customer = data.customerIdentifier,
shop = data.shopId
})
-- Send Discord notification
exports['your-logging']:Log('customer-unbanned', {
shop = data.shopName,
customer = data.customerName,
unbannedBy = data.unbannedBy,
originalReason = data.originalBanReason,
banDuration = data.banDuration .. ' days'
})
end)