diff --git a/framework/core/src/Extension/Extension.php b/framework/core/src/Extension/Extension.php index 33ad9ff9b..22f9f2380 100644 --- a/framework/core/src/Extension/Extension.php +++ b/framework/core/src/Extension/Extension.php @@ -86,9 +86,18 @@ class Extension implements Arrayable */ public function __construct($path, $composerJson) { - $this->id = end(explode('/', $path)); $this->path = $path; $this->composerJson = $composerJson; + $this->assignId(); + } + + /** + * Assigns the id for the extension used globally. + */ + protected function assignId() + { + $segments = explode('/', $this->path); + $this->id = end($segments); } /**