diff options
author | vipsoft <vipsoft@59fd770c-687e-43c8-a1e3-f5a4ff64c105> | 2010-03-22 19:59:15 +0300 |
---|---|---|
committer | vipsoft <vipsoft@59fd770c-687e-43c8-a1e3-f5a4ff64c105> | 2010-03-22 19:59:15 +0300 |
commit | 1312cb9da2c7b909387cadaefaef405033e44f96 (patch) | |
tree | 090ef13b09d8bcbef9e388041738386bf94f6580 /plugins/SitesManager/SitesManager.php | |
parent | 908ea3d38e466867c98e783c254845fc233c58eb (diff) |
refs #43 - getIp() returns a stringified, unsigned number; changed unit test to match getIp()'s behaviour; SitesManager converts min/max to non-negative numbers
Diffstat (limited to 'plugins/SitesManager/SitesManager.php')
-rw-r--r-- | plugins/SitesManager/SitesManager.php | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/plugins/SitesManager/SitesManager.php b/plugins/SitesManager/SitesManager.php index 01f4b703de..746f954918 100644 --- a/plugins/SitesManager/SitesManager.php +++ b/plugins/SitesManager/SitesManager.php @@ -75,7 +75,12 @@ class Piwik_SitesManager extends Piwik_Plugin { continue; } - $ipRanges[] = $ipRange; + + // long data type is signed; convert to stringified unsigned number + $ipRange[0] = sprintf("%u", $ipRange[0]); + $ipRange[1] = sprintf("%u", $ipRange[1]); + + $ipRanges[] = $ipRange; } return $ipRanges; } @@ -100,4 +105,3 @@ class Piwik_SitesManager extends Piwik_Plugin Piwik_AddAdminMenu('SitesManager_MenuSites', array('module' => 'SitesManager', 'action' => 'index')); } } - |