@@ -1183,14 +1183,14 @@ public void VerifyInsert(Database db, DBResultSet results, const char[] error, D
1183
1183
}
1184
1184
1185
1185
// Kick player
1186
- if (GetClientUserId (client ) == UserId )
1187
- {
1188
- char length [32 ];
1189
- if (time == 0 )
1190
- FormatEx (length , sizeof (length ), " permament" );
1191
- else
1192
- FormatEx (length , sizeof (length ), " %d %s " , time , time == 1 ? " minute" : " minutes" );
1193
- KickClient (client , " %t \n\n %t " , " Banned Check Site" , WebsiteAddress , " Kick Reason" , admin , Reason , length );
1186
+ if (GetClientUserId (client ) == UserId )
1187
+ {
1188
+ char length [32 ];
1189
+ if (time == 0 )
1190
+ FormatEx (length , sizeof (length ), " permament" );
1191
+ else
1192
+ FormatEx (length , sizeof (length ), " %d %s " , time , time == 1 ? " minute" : " minutes" );
1193
+ KickClient (client , " %t \n\n %t " , " Banned Check Site" , WebsiteAddress , " Kick Reason" , admin , Reason , length );
1194
1194
}
1195
1195
}
1196
1196
@@ -1295,7 +1295,6 @@ public void SelectUnbanCallback(Database db, DBResultSet results, const char[] e
1295
1295
dataPack .ReadString (reason , sizeof (reason ));
1296
1296
dataPack .ReadString (arg , sizeof (arg ));
1297
1297
dataPack .ReadString (adminAuth , sizeof (adminAuth ));
1298
- delete dataPack ;
1299
1298
1300
1299
db .Escape (reason , unbanReason , sizeof (unbanReason ));
1301
1300
@@ -1307,6 +1306,7 @@ public void SelectUnbanCallback(Database db, DBResultSet results, const char[] e
1307
1306
{
1308
1307
PrintToChat (admin , " %s sm_unban failed" , Prefix );
1309
1308
}
1309
+ delete dataPack ;
1310
1310
return ;
1311
1311
}
1312
1312
@@ -1319,6 +1319,7 @@ public void SelectUnbanCallback(Database db, DBResultSet results, const char[] e
1319
1319
} else {
1320
1320
PrintToServer (" %s No active bans found for that filter" , Prefix );
1321
1321
}
1322
+ delete dataPack ;
1322
1323
return ;
1323
1324
}
1324
1325
@@ -2562,14 +2563,14 @@ stock void UTIL_InsertTempBan(int time, const char[] name, const char[] auth, co
2562
2563
2563
2564
ServerCommand (buffer );
2564
2565
2565
- if (IsClientInGame (client ))
2566
+ if (IsClientInGame (client ))
2566
2567
{
2567
- char length [32 ];
2568
- if (time == 0 )
2569
- FormatEx (length , sizeof (length ), " permament" );
2570
- else
2571
- FormatEx (length , sizeof (length ), " %d %s " , time , time == 1 ? " minute" : " minutes" );
2572
- KickClient (client , " %t \n\n %t " , " Banned Check Site" , WebsiteAddress , " Kick Reason" , admin , reason , length );
2568
+ char length [32 ];
2569
+ if (time == 0 )
2570
+ FormatEx (length , sizeof (length ), " permament" );
2571
+ else
2572
+ FormatEx (length , sizeof (length ), " %d %s " , time , time == 1 ? " minute" : " minutes" );
2573
+ KickClient (client , " %t \n\n %t " , " Banned Check Site" , WebsiteAddress , " Kick Reason" , admin , reason , length );
2573
2574
}
2574
2575
2575
2576
char banName [128 ], banReason [256 ], query [512 ];
@@ -2651,10 +2652,10 @@ stock void PrepareBan(int client, int target, int time, char[] reason, int size)
2651
2652
}
2652
2653
}
2653
2654
LogAction (client , target , " \" %L \" banned \" %L \" (minutes \" %d \" ) (reason \" %s \" )" , client , target , time , reason );
2654
- char length [32 ];
2655
- if (time == 0 )
2656
- FormatEx (length , sizeof (length ), " permament" );
2657
- else
2655
+ char length [32 ];
2656
+ if (time == 0 )
2657
+ FormatEx (length , sizeof (length ), " permament" );
2658
+ else
2658
2659
FormatEx (length , sizeof (length ), " %d %s " , time , time == 1 ? " minute" : " minutes" );
2659
2660
if (time > 5 || time == 0 )
2660
2661
time = 5 ;
0 commit comments