Remove obsolete register script traces

This commit is contained in:
Thomas Gelf 2014-02-14 13:37:45 +00:00
parent c68bce2f3d
commit 7dbede12fb
3 changed files with 12 additions and 38 deletions

View File

@ -274,7 +274,6 @@ class Manager
$this->enabledDirs[$name] = $link; $this->enabledDirs[$name] = $link;
$this->loadModule($name); $this->loadModule($name);
$this->getModule($name)->launchRegisterScript();
return $this; return $this;
} }

View File

@ -101,13 +101,6 @@ class Module
*/ */
private $runScript; private $runScript;
/**
* Module initialization script
*
* @var string
*/
private $registerScript;
/** /**
* Module configuration script * Module configuration script
* *
@ -152,18 +145,17 @@ class Module
*/ */
public function __construct(ApplicationBootstrap $app, $name, $basedir) public function __construct(ApplicationBootstrap $app, $name, $basedir)
{ {
$this->app = $app; $this->app = $app;
$this->name = $name; $this->name = $name;
$this->basedir = $basedir; $this->basedir = $basedir;
$this->cssdir = $basedir . '/public/css'; $this->cssdir = $basedir . '/public/css';
$this->libdir = $basedir . '/library'; $this->libdir = $basedir . '/library';
$this->configdir = $basedir . '/config'; $this->configdir = $basedir . '/config';
$this->localedir = $basedir . '/application/locale'; $this->localedir = $basedir . '/application/locale';
$this->formdir = $basedir . '/application/forms'; $this->formdir = $basedir . '/application/forms';
$this->controllerdir = $basedir . '/application/controllers'; $this->controllerdir = $basedir . '/application/controllers';
$this->runScript = $basedir . '/run.php'; $this->runScript = $basedir . '/run.php';
$this->registerScript = $basedir . '/register.php'; $this->configScript = $basedir . '/configuration.php';
$this->configScript = $basedir . '/configuration.php';
} }
/** /**
@ -511,16 +503,6 @@ class Module
return $this; return $this;
} }
/**
* Run module registration script
*
* @return self
*/
public function launchRegisterScript()
{
return $this->includeScript($this->registerScript);
}
/** /**
* Run module bootstrap script * Run module bootstrap script
* *
@ -540,14 +522,13 @@ class Module
*/ */
protected function includeScript($file) protected function includeScript($file)
{ {
if (is_readable($file) === true) { if (file_exists($file) && is_readable($file) === true) {
include($file); include($file);
} }
return $this; return $this;
} }
/** /**
* Run module config script * Run module config script
*/ */

View File

@ -1,6 +0,0 @@
<?php
/*
* register.php
*
* This file runs only on installation
*/