ModPlus available also for non-logged in users.

This commit is contained in:
Mikael Nordfeldth 2014-06-23 20:30:00 +02:00
parent 725af5edd0
commit 41a233f106
3 changed files with 4 additions and 7 deletions

View File

@ -43,22 +43,19 @@ class ModPlusPlugin extends Plugin
} }
/** /**
* Load JS at runtime if we're logged in. * Load JS at runtime.
* *
* @param Action $action * @param Action $action
* @return boolean hook result * @return boolean hook result
*/ */
function onEndShowScripts($action) function onEndShowScripts(Action $action)
{ {
$user = common_current_user(); $action->script($this->path('js/modplus.js'));
if ($user) {
$action->script($this->path('modplus.js'));
}
return true; return true;
} }
public function onEndShowStylesheets(Action $action) { public function onEndShowStylesheets(Action $action) {
$action->cssLink($this->path('modplus.css')); $action->cssLink($this->path('css/modplus.css'));
return true; return true;
} }