started to make it compatible with latest Piwik master version