Skip to content

Commit

Permalink
Fix bug parse error
Browse files Browse the repository at this point in the history
Report by vvp <[email protected]>

class Workbench extends Component {
  public $workingDir = __DIR__ . '/../../../../workbench' ;
... ...
... ...

PHP (5.5.15 on a XAAMP setup) complains with the following error:
Parse error: syntax error, unexpected '.', expecting ',' or ';'

It seems that the string concatenation is the culprit here.
Please correct!

Regards,
VVP
  • Loading branch information
johnitvn committed Jul 31, 2015
1 parent 9c48a93 commit 4f24db4
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/Workbench.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ class Workbench extends Component {
/**
* @var string The workbench workspace directory.
*/
public $workingDir = __DIR__ . '/../../../../workbench';
public $workingDir;

/**
*
Expand Down Expand Up @@ -44,7 +44,7 @@ public static function getInstance(Application $app) {
} else {
$workbench = $app->get("workbench");
}

$this->workingDir = dirname(dirname(dirname(__DIR__))) . '/workbench';
// If workbench workspace not exist. return null
if (!file_exists($workbench->workingDir)) {
return null;
Expand Down

0 comments on commit 4f24db4

Please sign in to comment.