Skip to content

Commit

Permalink
Fixed Class PrettyRoutes\ServiceProvider not found after update
Browse files Browse the repository at this point in the history
  • Loading branch information
Andrey Helldar committed Oct 20, 2020
1 parent 3f00ae9 commit c928f6d
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,13 +30,13 @@ If your using autodiscovery in Laravel, it should just work.
Otherwise - add to your `config/app.php` providers array to where all your package providers are (before your app's providers):

```php
PrettyRoutes\AppServiceProvider::class,
PrettyRoutes\ServiceProvider::class,
```

By default, the package exposes a `/routes` url. If you wish to configure this, publish the config.

```bash
php artisan vendor:publish --provider="PrettyRoutes\AppServiceProvider"
php artisan vendor:publish --provider="PrettyRoutes\ServiceProvider"
```

If accessing `/routes` isn't working, ensure that you've included the provider within the same area as all your package providers (before all your app's providers) to ensure it takes priority.
Expand Down
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@
"laravel": {
"providers": [
"PrettyRoutes\\BladeServiceProvider",
"PrettyRoutes\\AppServiceProvider"
"PrettyRoutes\\ServiceProvider"
]
}
}
Expand Down
2 changes: 1 addition & 1 deletion src/AppServiceProvider.php → src/ServiceProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

use Illuminate\Support\ServiceProvider as BaseServiceProvider;

class AppServiceProvider extends BaseServiceProvider
class ServiceProvider extends BaseServiceProvider
{
public function register()
{
Expand Down
4 changes: 2 additions & 2 deletions tests/TestCase.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
namespace Tests;

use Orchestra\Testbench\TestCase as BaseTestCase;
use PrettyRoutes\AppServiceProvider;
use PrettyRoutes\ServiceProvider;

abstract class TestCase extends BaseTestCase
{
Expand All @@ -15,7 +15,7 @@ protected function getEnvironmentSetUp($app)

protected function getPackageProviders($app): array
{
return [AppServiceProvider::class];
return [ServiceProvider::class];
}

protected function setRoutes($app)
Expand Down

0 comments on commit c928f6d

Please sign in to comment.