Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/matomo-org/matomo.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormattab <matthieu.aubry@gmail.com>2013-05-24 15:23:17 +0400
committermattab <matthieu.aubry@gmail.com>2013-05-24 15:23:17 +0400
commit58c88c1b2980ee1c02a47cb3d35de1480402e6ac (patch)
treeb77a766fece69ee3888c4003799483da687b2619 /plugins/DevicesDetection/functions.php
parent4f4d377876adcf698c00ca2141f9cff26bf75a83 (diff)
Refs #3612
* making tests pass! * enabling DevicesDetection tests, even though DevicesDetection plugin is disabled by default.
Diffstat (limited to 'plugins/DevicesDetection/functions.php')
-rw-r--r--plugins/DevicesDetection/functions.php12
1 files changed, 5 insertions, 7 deletions
diff --git a/plugins/DevicesDetection/functions.php b/plugins/DevicesDetection/functions.php
index 34f8ed8690..0812741aec 100644
--- a/plugins/DevicesDetection/functions.php
+++ b/plugins/DevicesDetection/functions.php
@@ -130,18 +130,16 @@ function Piwik_getOsFullNameExtended($label)
if (!empty($label) && $label != ";") {
$os = substr($label, 0, 3);
$ver = substr($label, 4, 15);
- $osFullName = array_search($os, UserAgentParserEnhanced::$osShorts);
- if ($osFullName) {
- if (in_array($os, UserAgentParserEnhanced::$osFamilies['Windows'])) {
- return $osFullName;
- } else {
- return trim($osFullName . " " . $ver);
- }
+ $name = UserAgentParserEnhanced::getOsNameFromId($os, $ver);
+ if(!empty($name)) {
+ return $name;
}
}
return Piwik_Translate('General_Unknown');
}
+
+
function Piwik_getOsLogoExtended($label)
{
$short = substr($label, 0, 3);