0
0
mirror of https://github.com/ezyang/htmlpurifier.git synced 2025-01-03 05:11:52 +00:00

Slight optimization in LinkTypes using array_keys().

Signed-off-by: Edward Z. Yang <edwardzyang@thewritingpot.com>
This commit is contained in:
Edward Z. Yang 2008-07-08 21:47:52 -04:00
parent 0ec9731184
commit 3a4b92da81

View File

@ -42,10 +42,7 @@ class HTMLPurifier_AttrDef_HTML_LinkTypes extends HTMLPurifier_AttrDef
} }
if (empty($ret_lookup)) return false; if (empty($ret_lookup)) return false;
$string = implode(' ', array_keys($ret_lookup));
$ret_array = array();
foreach ($ret_lookup as $part => $bool) $ret_array[] = $part;
$string = implode(' ', $ret_array);
return $string; return $string;