mirror of
https://github.com/flarum/core.git
synced 2025-07-25 02:31:17 +02:00
refactoring to support array closures migrations and fixed issues with previous pr for extension rewriting
This commit is contained in:
committed by
Franz Liedke
parent
2b5dab73f9
commit
e4412178b1
@@ -182,7 +182,7 @@ class ExtensionManager
|
||||
{
|
||||
if ($extension->hasAssets()) {
|
||||
$this->filesystem->copyDirectory(
|
||||
$this->app->basePath() . '/extensions/' . $extension->getId() . '/assets',
|
||||
$extension->getPath() . '/assets',
|
||||
$this->app->basePath() . '/assets/extensions/' . $extension->getId()
|
||||
);
|
||||
}
|
||||
@@ -219,7 +219,7 @@ class ExtensionManager
|
||||
public function migrate(Extension $extension, $up = true)
|
||||
{
|
||||
if ($extension->hasMigrations()) {
|
||||
$migrationDir = public_path('extensions/' . $extension->getId() . '/migrations');
|
||||
$migrationDir = $extension->getPath() . '/migrations';
|
||||
|
||||
$this->app->bind('Illuminate\Database\Schema\Builder', function ($container) {
|
||||
return $container->make('Illuminate\Database\ConnectionInterface')->getSchemaBuilder();
|
||||
@@ -240,7 +240,7 @@ class ExtensionManager
|
||||
*/
|
||||
public function migrateDown(Extension $extension)
|
||||
{
|
||||
$this->migrate($extension->getId(), false);
|
||||
$this->migrate($extension, false);
|
||||
}
|
||||
|
||||
public function getMigrator()
|
||||
|
Reference in New Issue
Block a user