mirror of
https://github.com/flarum/core.git
synced 2025-10-14 16:34:26 +02:00
Simplify interface of migration-related classes
Mostly, we only need a database connection, instead of one of Laravel's "connection resolvers". Again, this makes our life easier during installation, where we already instantiate a database connection. We can now use that to instantiate our own Migrator class, instead of using the IoC container to build one.
This commit is contained in:
@@ -22,7 +22,7 @@ class MigrationServiceProvider extends AbstractServiceProvider
|
||||
public function register()
|
||||
{
|
||||
$this->app->singleton('Flarum\Database\MigrationRepositoryInterface', function ($app) {
|
||||
return new DatabaseMigrationRepository($app['db'], 'migrations');
|
||||
return new DatabaseMigrationRepository($app['flarum.db'], 'migrations');
|
||||
});
|
||||
|
||||
$this->app->bind(MigrationCreator::class, function (Application $app) {
|
||||
|
Reference in New Issue
Block a user