By comparing $agent to the empty strict with loose equivalence (==) instead of strict equality (===), this permits matching more than just the empty string, according to the PHP type comparison truth table. Specifically, $agent will also match if it contains the string "0", rather than being empty, which I believe should be regarded as a false positive.
By comparing
$agent
to the empty strict with loose equivalence (==
) instead of strict equality (===
), this permits matching more than just the empty string, according to the PHP type comparison truth table. Specifically,$agent
will also match if it contains the string"0"
, rather than being empty, which I believe should be regarded as a false positive.