Skip to content
This repository has been archived by the owner on Jul 15, 2020. It is now read-only.

Commit

Permalink
Ensure package migration files are published separately
Browse files Browse the repository at this point in the history
  • Loading branch information
unicodeveloper committed Jul 14, 2020
1 parent 1047e56 commit 069ae15
Showing 1 changed file with 8 additions and 14 deletions.
22 changes: 8 additions & 14 deletions src/CloudinaryServiceProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,6 @@ public function boot()
{
$this->bootMacros();
$this->bootResources();
$this->bootMigrations();
$this->bootDirectives();
$this->bootComponents();
$this->bootCommands();
Expand Down Expand Up @@ -73,18 +72,6 @@ protected function bootResources()
$this->loadViewsFrom(__DIR__ . '/../resources/views', 'cloudinary');
}

/**
* Boot the package migrations.
*
* @return void
*/
protected function bootMigrations()
{
if ($this->app->runningInConsole()) {
$this->loadMigrationsFrom(__DIR__ . '/../database/migrations');
}
}

/**
* Boot the package directives.
*
Expand Down Expand Up @@ -143,9 +130,16 @@ protected function bootPublishing()

$this->publishes(
[
$config => config_path('cloudinary.php')
$config => $this->app->configPath('cloudinary.php'),
]
);

$this->publishes(
[
__DIR__.'/../database/migrations' => $this->app->databasePath('migrations'),
],
'laravel-cloudinary-migrations'
);
}
}

Expand Down

0 comments on commit 069ae15

Please sign in to comment.