Skip to content

Commit

Permalink
4006 serialize (#4013)
Browse files Browse the repository at this point in the history
* Add new arguments key and target. Make it possible use not only default target for db connections

* Replace serialize/unserialize as not supported
  • Loading branch information
LOBsTerr authored and enzolutions committed Jul 3, 2019
1 parent 04f43a7 commit fca9572
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 1 deletion.
20 changes: 20 additions & 0 deletions src/Extension/Extension.php
Original file line number Diff line number Diff line change
Expand Up @@ -160,4 +160,24 @@ public function getJsTestsPath($fullPath = false)
{
return $this->getTestsSourcePath($fullPath) . '/FunctionalJavascript';
}

/**
* @param BaseExtension $extension
*/
function loadFromParentObj(BaseExtension $extension)
{
$objValues = get_object_vars($extension);
foreach($objValues AS $key => $value)
{
$this->$key = $value;
}
}

/**
* @param $root
*/
function setRoot($root) {
$this->root = $root;
}

}
4 changes: 3 additions & 1 deletion src/Extension/Manager.php
Original file line number Diff line number Diff line change
Expand Up @@ -311,7 +311,9 @@ private function createExtension($extension)
$extension->getPathname(),
$extension->getExtensionFilename()
);
$consoleExtension->unserialize($extension->serialize());

$consoleExtension->loadFromParentObj($extension);
$consoleExtension->setRoot($this->appRoot);

return $consoleExtension;
}
Expand Down

0 comments on commit fca9572

Please sign in to comment.