Bug #82
Error when banning from web
| Status: | Closed | Start: | 06/14/2008 | |
| Priority: | Normal | Due date: | ||
| Assigned to: | Erik Minekus | % Done: | 100% |
|
| Category: | Web Panel | |||
| Target version: | 1.1.1 | |||
Description
If you go to add a ban of a player that was temp banned in the past but has been unbanned as a result of the ban expiring you will get the following error:
SteamID: STEAM_0:1:xxxxxxx is already banned.
This is despite the fact that they obviously are not banned but where banned in the past.
This is with the latest 1.1.1c (I updated all my code to the new stuff posted in the Repository)
Associated revisions
History
Updated by Recon _ 204 days ago
includes/sb-callback.php, AddBan, line 1263 needs to have the select statement adjusted.
I the below should resolve your problem. I have tested it on my instance of SB and it works perfectly.
Line 1263 of includes/sb-callback.php
Before
$chk = $GLOBALS['db']->GetRow("SELECT count(bid) AS count FROM ".DB_PREFIX."_bans WHERE authid = ?", array($steam));
After
$chk = $GLOBALS['db']->GetRow("SELECT count(bid) AS count FROM ".DB_PREFIX."_bans WHERE authid = ? AND (`length` = '0' OR `ends` > UNIX_TIMESTAMP())", array($steam));
TY to Tsunami for helping with the perma ban issue.
Updated by Erik Minekus 204 days ago
- Assigned to set to Erik Minekus
Updated by Erik Minekus 204 days ago
- Status changed from New to Closed
- Target version set to 1.1.1
- % Done changed from 0 to 100
Fixed in r80