function piwik_update_7203 in Piwik Web Analytics 7.2
Same name and namespace in other branches
- 6.2 piwik.install \piwik_update_7203()
Path visibility filter setting should hide "batch" path.
File
- ./
piwik.install, line 232 - Installation file for Piwik - Web analytics module.
Code
function piwik_update_7203() {
// Latest pages setting.
$pages = array(
'admin',
'admin/*',
'user/*/*',
'node/add*',
'node/*/*',
);
$diff = array_diff($pages, preg_split('/(\\r\\n?|\\n)/', variable_get('piwik_pages', implode("\n", $pages))));
if (empty($diff)) {
// No diff to latest settings found. Update with new settings.
$pages = array(
'admin',
'admin/*',
'batch',
'node/add*',
'node/*/*',
'user/*/*',
);
variable_set('piwik_pages', implode("\n", $pages));
return t('Added "batch" to path visibility filter setting.');
}
else {
return t('Custom path visibility filter setting found. Update skipped!');
}
}