summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFrug <frugen@gmail.com>2014-07-01 19:24:11 -0400
committerFrug <frugen@gmail.com>2014-07-01 19:26:50 -0400
commit60bbdf2543aa3b93d1321ace76a570be142f64b3 (patch)
tree9f2c3628957601416c4cafd75f9b669baa3af9a0
parentda808498c2bc2676d1500f5c44da1aabeb4500c4 (diff)
downloadAJAX-Chat-60bbdf2543aa3b93d1321ace76a570be142f64b3.zip
AJAX-Chat-60bbdf2543aa3b93d1321ace76a570be142f64b3.tar.gz
AJAX-Chat-60bbdf2543aa3b93d1321ace76a570be142f64b3.tar.bz2
accept 0 for ban time - thanks @micheal-swiggs issue #39
-rw-r--r--chat/changelog.txt3
-rw-r--r--chat/lib/class/AJAXChat.php2
2 files changed, 3 insertions, 2 deletions
diff --git a/chat/changelog.txt b/chat/changelog.txt
index 1e3e261..ff0f55b 100644
--- a/chat/changelog.txt
+++ b/chat/changelog.txt
@@ -858,4 +858,5 @@ New Features:
Bugfixes:
- HTML is now stripped from [IMG] tag URLs, and tag parsing errors will no longer crash chat. - thanks to gWorldz
-- Nesting an [IMG] inside a [URL] tag will now only open the URL instead of also opening the image - thanks to James Almer. \ No newline at end of file
+- Nesting an [IMG] inside a [URL] tag will now only open the URL instead of also opening the image - thanks to James Almer.
+- Users can now be kicked for 0 minutes, which is effectively a kick and not a ban - thanks to micheal-swiggs \ No newline at end of file
diff --git a/chat/lib/class/AJAXChat.php b/chat/lib/class/AJAXChat.php
index 2cf7aa1..ac9c71b 100644
--- a/chat/lib/class/AJAXChat.php
+++ b/chat/lib/class/AJAXChat.php
@@ -1627,7 +1627,7 @@ class AJAXChat {
return;
}
- $banMinutes = $banMinutes ? $banMinutes : $this->getConfig('defaultBanTime');
+ $banMinutes = ($banMinutes !== null) ? $banMinutes : $this->getConfig('defaultBanTime');
if($banMinutes) {
// Ban User for the given time in minutes: