Fix warning if searching two whitespaces and formatting

This commit is contained in:
Igor Scheller 2018-12-26 19:39:40 +01:00
parent 26f58b8156
commit 36830c43e7
2 changed files with 19 additions and 17 deletions

View File

@ -79,11 +79,13 @@ function admin_arrive()
$match = false; $match = false;
$index = join(' ', $usr->toArray()); $index = join(' ', $usr->toArray());
foreach ($tokens as $t) { foreach ($tokens as $t) {
if (stristr($index, trim($t))) { $t = trim($t);
if (!empty($t) && stristr($index, $t)) {
$match = true; $match = true;
break; break;
} }
} }
if (!$match) { if (!$match) {
continue; continue;
} }