Fixes ValueError: invalid literal for int() with base 10: '-' http://forum.piwik.org/read.php?2,106854
Reverting part of https://github.com/piwik/piwik/pull/120/files