Skip to content

Commit 5a006d8

Browse files
committed
Merge branch 'develop'
2 parents e559ce9 + c0b45da commit 5a006d8

File tree

2 files changed

+5
-7
lines changed

2 files changed

+5
-7
lines changed

README.md

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -22,10 +22,10 @@ Install via composer
2222

2323
composer require stolz/laravel-html-tidy --dev
2424

25-
Then edit `config/app.php` and add the service provider within the `providers` array:
25+
If you are using an old version of Laravel without the package discovery feature (or if you have disabled it), then you have to manually edit `config/app.php` file and add the service provider to the `providers` array:
2626

2727
'providers' => [
28-
//...
28+
...
2929
'Stolz\HtmlTidy\ServiceProvider',
3030
],
3131

@@ -44,9 +44,7 @@ If you want the middleware to be run only on specific routes, add the class in t
4444

4545
Now you can use it in your `routes.php` file
4646

47-
get('some/url', ['middleware' => 'tidy', function() {
48-
return view('home');
49-
}]);
47+
Route::get('some/url', function () {...})->middleware('tidy');
5048

5149
Conversely if you want the middleware to be run on every HTTP request to your application, add the class in the `$middleware` property of your `app/Http/Kernel.php` file.
5250

composer.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,8 @@
1212
"require": {
1313
"php": ">=5.4",
1414
"ext-tidy": "*",
15-
"illuminate/support": "5.*",
16-
"illuminate/http": "5.*"
15+
"illuminate/support": "^5|^6",
16+
"illuminate/http": "^5|^6"
1717
},
1818
"require-dev": {
1919
"squizlabs/php_codesniffer": "2.*"

0 commit comments

Comments
 (0)