Skip to content

Commit

Permalink
fix serviceprovider
Browse files Browse the repository at this point in the history
  • Loading branch information
freekmurze committed Oct 8, 2015
1 parent 23c2905 commit 75a9923
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@

All Notable changes to Laravel-Analytics will be documented in this file

## 1.2.2
- An injected `Spatie\Analytics`-object will now be properly configured

## 1.2.1
- Removed a var_dump-call that was not supposed to be there

Expand Down
4 changes: 3 additions & 1 deletion src/LaravelAnalyticsServiceProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -21,14 +21,16 @@ public function boot()
*/
public function register()
{
$this->app->bind('laravelAnalytics', function ($app) {
$this->app->bind(LaravelAnalytics::class, function ($app) {

$googleApiHelper = $this->getGoogleApiHelperClient();

$laravelAnalytics = new LaravelAnalytics($googleApiHelper, Config::get('laravel-analytics.siteId'));

return $laravelAnalytics;
});

$this->app->alias(LaravelAnalytics::class, 'laravelAnalytics');
}

/**
Expand Down

0 comments on commit 75a9923

Please sign in to comment.