Skip to content
This repository has been archived by the owner on May 12, 2021. It is now read-only.

Commit

Permalink
fixed boot path issue
Browse files Browse the repository at this point in the history
  • Loading branch information
mauris committed Mar 14, 2014
1 parent 6bb8c5d commit a1eb2d4
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/Packfire/Framework/Bootstrap.php
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ public function __construct($bootPath = null, ContainerInterface $container = nu
$this->bootPath = $bootPath;
if (!$this->bootPath) {
$backtrace = debug_backtrace();
$this->bootPath = $backtrace[0]['file'];
$this->bootPath = pathinfo($backtrace[0]['file'], PATHINFO_DIRNAME);
}
}

Expand Down
2 changes: 1 addition & 1 deletion test/Packfire/Framework/BootstrapTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ public function testGetContainer2()
public function testBootPath()
{
$bootstrap = new Bootstrap();
$this->assertEquals(__FILE__, $bootstrap->bootPath());
$this->assertEquals(pathinfo(__FILE__, PATHINFO_DIRNAME), $bootstrap->bootPath());
}

public function testRun()
Expand Down

0 comments on commit a1eb2d4

Please sign in to comment.