Fixed Bug in Mobile Browser check

lsKevin

Active member
In XenForo_Visitor::isBrowsingWith(), there's a couple strpos calls that need to have their parameters swapped.

Code:
else if (strpos('SymbianOS', $ua) !== false)
{
    return true;
}
else if (strpos('Silk-Accelerated', $ua) !== false) // Amazon Silk
{
    return true;
}

should be

Code:
else if (strpos($ua, 'SymbianOS') !== false)
{
    return true;
}
else if (strpos($ua, 'Silk-Accelerated') !== false) // Amazon Silk
{
    return true;
}

This was found on version 1.5.7. I do not have 1.5.8 to verify.

Cheers,
Kevin
 
Top Bottom