Skip to content
This repository was archived by the owner on May 18, 2020. It is now read-only.

Commit 11e817b

Browse files
Use different Doctrine package + register namespace in driver chain
1 parent 9726f97 commit 11e817b

File tree

3 files changed

+8
-9
lines changed

3 files changed

+8
-9
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313

1414
Include the service provider in `config/app.php`
1515
```php
16-
'Mitch\LaravelDoctrine\LaravelDoctrineServiceProvider',
16+
'Brouwers\LaravelDoctrine\DoctrineServiceProvider',
1717
'Maatwebsite\Usher\UsherServiceProvider'
1818
```
1919

composer.json

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -16,17 +16,11 @@
1616
"email": "patrick@maatwebsite.nl"
1717
}
1818
],
19-
"repositories": [
20-
{
21-
"type": "vcs",
22-
"url": "git@github.com:Maatwebsite/laravel-doctrine.git"
23-
}
24-
],
2519
"require": {
2620
"php": ">=5.4.0",
2721
"nesbot/carbon": "~1.0",
2822
"beberlei/assert": "~2.3",
29-
"mitchellvanw/laravel-doctrine": "dev-develop"
23+
"brouwers/laravel-doctrine": "~1.0.0"
3024
},
3125
"require-dev": {
3226
"phpunit/phpunit": "~4.5",

src/UsherServiceProvider.php

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,11 @@ public function boot()
2828
*/
2929
public function register()
3030
{
31+
// Add namespace to driver chain
32+
$this->app['events']->listen('doctrine.driver-chain::booted', function ($driver, $chain) {
33+
$chain->addDriver($driver, 'Maatwebsite');
34+
});
35+
3136
$this->bindUserEntity();
3237
$this->bindRepositories();
3338
$this->extendAuthManager();
@@ -39,7 +44,7 @@ public function register()
3944
*/
4045
protected function extendAuthManager()
4146
{
42-
// Set Usher as default auth drive
47+
// Set Usher as default auth driver
4348
$this->app['config']->set('auth.driver', 'usher');
4449

4550
// Extend the auth manager

0 commit comments

Comments
 (0)