[geeklog-hg] geeklog: Allow spaces in Personal Blacklist records of the Spam-...
geeklog-cvs at lists.geeklog.net
geeklog-cvs at lists.geeklog.net
Mon Feb 3 20:59:30 EST 2014
changeset 9476:ec8d5f57bd79
url: http://project.geeklog.net/cgi-bin/hgwebdir.cgi/geeklog/rev/ec8d5f57bd79
user: Tom <websitemaster at cogeco.net>
date: Mon Feb 03 20:57:27 2014 -0500
description:
Allow spaces in Personal Blacklist records of the Spam-X plugin
diffstat:
plugins/spamx/BaseAdmin.class.php | 7 +++++--
plugins/spamx/EditBlackList.Admin.class.php | 4 ++--
2 files changed, 7 insertions(+), 4 deletions(-)
diffs (43 lines):
diff -r 1f6433ff633f -r ec8d5f57bd79 plugins/spamx/BaseAdmin.class.php
--- a/plugins/spamx/BaseAdmin.class.php Mon Feb 03 21:32:20 2014 +0900
+++ b/plugins/spamx/BaseAdmin.class.php Mon Feb 03 20:57:27 2014 -0500
@@ -112,16 +112,19 @@
* Adds an entry to database
*
* @param string $entry
+ * @param string $spaces
* @return boolean true = success, false = otherwise
*/
- protected function addEntry($entry)
+ protected function addEntry($entry, $spaces = false)
{
global $_TABLES;
$retval = true;
if (!empty($entry)) {
- $entry = str_replace(' ', '', $entry);
+ if (!$spaces) {
+ $entry = str_replace(' ', '', $entry);
+ }
$entry = DB_escapeString($entry);
$count = DB_getItem(
$_TABLES['spamx'],
diff -r 1f6433ff633f -r ec8d5f57bd79 plugins/spamx/EditBlackList.Admin.class.php
--- a/plugins/spamx/EditBlackList.Admin.class.php Mon Feb 03 21:32:20 2014 +0900
+++ b/plugins/spamx/EditBlackList.Admin.class.php Mon Feb 03 20:57:27 2014 -0500
@@ -55,12 +55,12 @@
break;
case $LANG_SX00['addentry']:
- $this->addEntry($entry);
+ $this->addEntry($entry, true);
break;
case $LANG_SX00['addcen']:
foreach ($_CONF['censorlist'] as $entry) {
- $this->addEntry($entry);
+ $this->addEntry($entry, true);
}
break;
More information about the geeklog-cvs
mailing list