Skip to content

Commit

Permalink
Running per-daemon setup after plugin setup.
Browse files Browse the repository at this point in the history
Allows the daemon setup to use plugins. In my case the config plugin loads stuff that is needed in my daemon setup. Fixes/ avoids [issue 1](shaneharter#1)
  • Loading branch information
vitch committed Oct 6, 2011
1 parent 085fd0b commit 8091b44
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions Core/Daemon.php
Original file line number Diff line number Diff line change
Expand Up @@ -266,12 +266,12 @@ protected function check_environment(Array $errors = array())
*/
private function init()
{
// Run the per-daemon setup
$this->setup();

// Setup any registered plugins
foreach($this->plugins as $plugin)
$this->{$plugin}->setup();

// Run the per-daemon setup
$this->setup();

// Set the initial lock and gracefully exit if another lock is detected
if ($lock = $this->lock->check())
Expand Down

0 comments on commit 8091b44

Please sign in to comment.