From: Timo Tijhof Date: Mon, 21 Nov 2016 23:02:06 +0000 (-0800) Subject: resourceloader: Combine UC Mini startup regex with others X-Git-Tag: 1.31.0-rc.0~4801 X-Git-Url: https://git.heureux-cyclage.org/?p=lhc%2Fweb%2Fwiklou.git;a=commitdiff_plain;h=213ecf166af5bd90c70aec4ae651cbb48d3a846c resourceloader: Combine UC Mini startup regex with others Follows-up 2b1da77. Also add "UC Mini" to the list of documented Grade C browsers, and leave a note about regex combinations. (Follows-up 5d166eb). Change-Id: I1b5307aec7fd1734d8a79a2256e061fceb20fa35 --- diff --git a/resources/src/startup.js b/resources/src/startup.js index 2050ca91cf..f9cfecf31b 100644 --- a/resources/src/startup.js +++ b/resources/src/startup.js @@ -44,6 +44,7 @@ mwPerformance.mark( 'mwLoadStart' ); * - Nokia's Ovi Browser * - MeeGo's browser * - Google Glass + * - UC Mini (speed mode on) * * Other browsers that pass the check are considered Grade X. * @@ -66,11 +67,10 @@ function isCompatible( str ) { // Hardcoded exceptions for browsers that pass the requirement but we don't want to // support in the modern run-time. + // Note: Please extend the regex instead of adding new ones !( - ua.match( /webOS\/1\.[0-4]|SymbianOS|Series60|NetFront|Opera Mini|S40OviBrowser|MeeGo|Android.+Glass/ ) || - ua.match( /PlayStation/i ) || - // UC Mini (speed mode on) - ua.match( /^Mozilla\/5\.0 .+ Gecko\/$/ ) + ua.match( /webOS\/1\.[0-4]|SymbianOS|Series60|NetFront|Opera Mini|S40OviBrowser|MeeGo|Android.+Glass|^Mozilla\/5\.0 .+ Gecko\/$/ ) || + ua.match( /PlayStation/i ) ) ); }