Skip to content

Commit

Permalink
compatibility with laravel 5.4
Browse files Browse the repository at this point in the history
  • Loading branch information
overtrue committed Jan 29, 2017
1 parent 08895b6 commit 903ab19
Showing 1 changed file with 3 additions and 11 deletions.
14 changes: 3 additions & 11 deletions src/ServiceProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,27 +14,19 @@ class ServiceProvider extends LaravelServiceProvider
*/
protected $defer = true;

/**
* Boot the provider.
*
* @return void
*/
public function boot()
{
//
}

/**
* Register the provider.
*
* @return void
*/
public function register()
{
$this->app->singleton([Pinyin::class => 'pinyin'], function($app)
$this->app->singleton(Pinyin::class, function($app)
{
return new Pinyin();
});

$this->app->alias(Pinyin::class, 'pinyin');
}

/**
Expand Down

0 comments on commit 903ab19

Please sign in to comment.