Committer: gprochaev
LJSUP-5987U trunk/cgi-bin/Apache/WURFL.pm
Modified: trunk/cgi-bin/Apache/WURFL.pm =================================================================== --- trunk/cgi-bin/Apache/WURFL.pm 2010-08-20 10:15:25 UTC (rev 17170) +++ trunk/cgi-bin/Apache/WURFL.pm 2010-08-20 10:32:29 UTC (rev 17171) @@ -10,8 +10,8 @@ my $user_agent = shift; if ($LJ::WURFL{'ua_keys_mobile'}) { - grep { $user_agent =~ /\Q$_\E/i } @{$LJ::WURFL{'ua_keys_mobile'}} - ? return 1 + my @redir = grep { $user_agent =~ /\Q$_\E/i } @{$LJ::WURFL{'ua_keys_mobile'}}; + scalar @redir ? return 1 : return 0; } @@ -60,7 +60,7 @@ return '' unless $remote; return '' unless LJ::u_equals($remote, LJ::load_user($username)); - if ($args =~ /show=(P|C|Y)/i) { + if ($args =~ /show=(P|C|Y)/i) { return "$mobile_domain/read/friends/?show=".lc($1); }