From: Mischa POSLAWSKY Date: Thu, 27 Apr 2017 23:31:34 +0000 (+0200) Subject: browser: truncate maximum usage score to 99 X-Git-Tag: v1.10~40 X-Git-Url: http://git.shiar.nl/sheet.git/commitdiff_plain/03abf85a7ec9775993766a3fd10cd2876aef0b42 browser: truncate maximum usage score to 99 Even in theory 100% should be impossible. --- diff --git a/browser.plp b/browser.plp index 5c3f769..a135d35 100644 --- a/browser.plp +++ b/browser.plp @@ -195,7 +195,7 @@ $canihas ||= { my $usagepct = 1; # score multiplier for 0..100 result # normalise usage percentage to only include shown browsers -$usagepct = 100.01 / featurescore({ # yes for every possible version +$usagepct = 99.99 / featurescore({ # yes for every possible version map { $_ => { map {$_ => 'y'} map { @{$_} } @{$versions{$_}} } } keys %versions }); $_->{usage} = featurescore($_->{stats}) * $usagepct