1
0
Fork 0
mirror of https://github.com/Oreolek/debug-toolbar.git synced 2024-04-24 05:11:17 +03:00

Added excluded_routes param (implements #32)

This commit is contained in:
biakaveron 2013-08-16 08:33:23 +04:00
parent 67cec4f7d5
commit af01a82c91
2 changed files with 12 additions and 0 deletions

View file

@ -488,6 +488,11 @@ abstract class Kohana_Debugtoolbar {
return FALSE;
}
if ( ! empty($config->excluded_routes) && in_array(Route::name(Request::initial()->route()), $config->excluded_routes))
{
return FALSE;
}
return TRUE;
}
}

View file

@ -42,4 +42,11 @@ $config['align'] = 'right';
*/
$config['secret_key'] = FALSE;
/**
* Disabled routes
*/
$config['excluded_routes'] = array(
'docs/media' // Userguide media route
);
return $config;