mirror of
https://github.com/phpbb/phpbb.git
synced 2025-08-03 23:37:39 +02:00
[ticket/10141] Save a hash lookup when value is not in cache.
PHPBB3-10141
This commit is contained in:
@@ -126,13 +126,17 @@ class auth
|
|||||||
|
|
||||||
while ($subseq = substr($seq, $i, 6))
|
while ($subseq = substr($seq, $i, 6))
|
||||||
{
|
{
|
||||||
if (!isset($seq_cache[$subseq]))
|
if (isset($seq_cache[$subseq]))
|
||||||
{
|
{
|
||||||
$seq_cache[$subseq] = str_pad(base_convert($subseq, 36, 2), 31, 0, STR_PAD_LEFT);
|
$converted = $seq_cache[$subseq];
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
$converted = $seq_cache[$subseq] = str_pad(base_convert($subseq, 36, 2), 31, 0, STR_PAD_LEFT);
|
||||||
}
|
}
|
||||||
|
|
||||||
// We put the original bitstring into the acl array
|
// We put the original bitstring into the acl array
|
||||||
$this->acl[$f] .= $seq_cache[$subseq];
|
$this->acl[$f] .= $converted;
|
||||||
$i += 6;
|
$i += 6;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user