Skip to content

Commit

Permalink
Merge pull request #3 from map-ir/v1
Browse files Browse the repository at this point in the history
V1
  • Loading branch information
arminnasiri committed Jul 13, 2019
2 parents 36d0fbd + ecefe74 commit 2aee5a2
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 3 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@ After publish the package files you must open mapir.php in config folder and set
add package service provider in bootstrap/app.php.
~~~
$app->register(Shiveh\Mapir\MapirLaravelServiceProvider::class);
class_alias(Shiveh\Mapir\MapirLaravelFacade::class, 'Mapir');
~~~
copy package config directory `vendor/shiveh/mapir/config` to root folder alongside with app directory.

Expand Down
9 changes: 6 additions & 3 deletions src/MapirLaravelServiceProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,12 @@ class MapirLaravelServiceProvider extends ServiceProvider
public function boot()
{
// for publish the Mapirlaravel config file to the main app config folder
$this->publishes([
__DIR__.'/../config/mapir.php' => config_path('mapir.php')
], 'mapir');
if (str_contains($this->app->version(), 'Lumen')) {
}else {
$this->publishes([
__DIR__ . '/../config/mapir.php' => config_path('mapir.php')
], 'mapir');
}
}

/**
Expand Down

0 comments on commit 2aee5a2

Please sign in to comment.