mirror of
https://github.com/flarum/framework.git
synced 2024-11-27 02:53:37 +08:00
Restore "originalUri" request attribute
This is helpful when Flarum is installed in subfolders. Fixes #778.
This commit is contained in:
parent
7850fc3b52
commit
8a4d6f5179
|
@ -22,6 +22,7 @@ use Illuminate\Contracts\Container\Container;
|
|||
use Middlewares\BasePath;
|
||||
use Middlewares\BasePathRouter;
|
||||
use Middlewares\RequestHandler;
|
||||
use Zend\Stratigility\Middleware\OriginalMessages;
|
||||
use Zend\Stratigility\MiddlewarePipe;
|
||||
|
||||
class InstalledApp implements AppInterface
|
||||
|
@ -61,6 +62,7 @@ class InstalledApp implements AppInterface
|
|||
$pipe = new MiddlewarePipe;
|
||||
|
||||
$pipe->pipe(new BasePath($this->basePath()));
|
||||
$pipe->pipe(new OriginalMessages);
|
||||
$pipe->pipe(
|
||||
new BasePathRouter([
|
||||
$this->subPath('api') => 'flarum.api.middleware',
|
||||
|
|
Loading…
Reference in New Issue
Block a user