Skip to content
This repository was archived by the owner on Aug 22, 2021. It is now read-only.

Commit 7bb62c5

Browse files
committed
Support route options. overtrue#3
1 parent 467b483 commit 7bb62c5

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

src/UEditorServiceProvider.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ public function register()
6565
protected function registerRoute($router)
6666
{
6767
if (!$this->app->routesAreCached()) {
68-
$router->group(['namespace' => __NAMESPACE__], function ($router) {
68+
$router->group(array_merge(['namespace' => __NAMESPACE__], config('ueditor.route.options', [])), function ($router) {
6969
$router->any(config('ueditor.route.name', '/ueditor/server'), 'UEditorController@serve');
7070
});
7171
}

src/config/ueditor.php

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,9 @@
1212
'disk' => 'public',
1313
'route' => [
1414
'name' => '/ueditor/server',
15+
'options' => [
16+
// middleware => 'auth',
17+
],
1518
],
1619

1720
// 上传 配置

0 commit comments

Comments
 (0)