Skip to content

Commit

Permalink
formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
taylorotwell committed Jan 28, 2019
1 parent 39b40de commit d73e672
Showing 1 changed file with 9 additions and 7 deletions.
16 changes: 9 additions & 7 deletions src/Illuminate/Foundation/Application.php
Original file line number Diff line number Diff line change
Expand Up @@ -95,11 +95,11 @@ class Application extends Container implements ApplicationContract, HttpKernelIn
protected $deferredServices = [];

/**
* The custom app path defined by the developer.
* The custom application path defined by the developer.
*
* @var string
*/
protected $path;
protected $appPath;

/**
* The custom database path defined by the developer.
Expand Down Expand Up @@ -297,23 +297,25 @@ protected function bindPathsInContainer()
/**
* Get the path to the application "app" directory.
*
* @param string $path Optionally, a path to append to the app path
* @param string $path
* @return string
*/
public function path($path = '')
{
return ($this->path ?: $this->basePath.DIRECTORY_SEPARATOR.'app').($path ? DIRECTORY_SEPARATOR.$path : $path);
$appPath = $this->appPath ?: $this->basePath.DIRECTORY_SEPARATOR.'app';

return $appPath.($path ? DIRECTORY_SEPARATOR.$path : $path);
}

/**
* Set the app directory.
* Set the application directory.
*
* @param string $path
* @return $this
*/
public function usePath($path)
public function useAppPath($path)
{
$this->path = $path;
$this->appPath = $path;

$this->instance('path', $path);

Expand Down

0 comments on commit d73e672

Please sign in to comment.