Update laravel related files

This commit is contained in:
DariusIII
2017-08-30 22:59:42 +02:00
parent f73e7285d3
commit 17ac1f9ea5
9 changed files with 48 additions and 11 deletions
+1
View File
@@ -1,4 +1,5 @@
2017-08-30 DariusIII
* Chg: Update laravel related files
* Chg: Add back yydecode support
* Chg: Check if user has been logged in already before serving the login page
* Chg: Update laravel/framework to version 5.5.0
+4 -2
View File
@@ -44,12 +44,14 @@ class Kernel extends ConsoleKernel
}
/**
* Register the Closure based commands for the application.
* Register the commands for the application.
*
* @return void
*/
protected function commands()
{
require base_path('routes/console.php');
$this->load(__DIR__.'/Commands');
require base_path('routes/console.php');
}
}
@@ -58,7 +58,7 @@ class RegisterController extends Controller
* Create a new user instance after a valid registration.
*
* @param array $data
* @return User
* @return \App\User
*/
protected function create(array $data)
{
+1
View File
@@ -18,6 +18,7 @@ class Kernel extends HttpKernel
\Illuminate\Foundation\Http\Middleware\ValidatePostSize::class,
\App\Http\Middleware\TrimStrings::class,
\Illuminate\Foundation\Http\Middleware\ConvertEmptyStringsToNull::class,
\App\Http\Middleware\TrustProxies::class,
];
/**
+2 -2
View File
@@ -2,9 +2,9 @@
namespace App\Http\Middleware;
use Illuminate\Cookie\Middleware\EncryptCookies as BaseEncrypter;
use Illuminate\Cookie\Middleware\EncryptCookies as Middleware;
class EncryptCookies extends BaseEncrypter
class EncryptCookies extends Middleware
{
/**
* The names of the cookies that should not be encrypted.
+2 -2
View File
@@ -2,9 +2,9 @@
namespace App\Http\Middleware;
use Illuminate\Foundation\Http\Middleware\TrimStrings as BaseTrimmer;
use Illuminate\Foundation\Http\Middleware\TrimStrings as Middleware;
class TrimStrings extends BaseTrimmer
class TrimStrings extends Middleware
{
/**
* The names of the attributes that should not be trimmed.
+29
View File
@@ -0,0 +1,29 @@
<?php
namespace App\Http\Middleware;
use Illuminate\Http\Request;
use Fideloper\Proxy\TrustProxies as Middleware;
class TrustProxies extends Middleware
{
/**
* The trusted proxies for this application.
*
* @var array
*/
protected $proxies;
/**
* The current proxy header mappings.
*
* @var array
*/
protected $headers = [
Request::HEADER_FORWARDED => 'FORWARDED',
Request::HEADER_X_FORWARDED_FOR => 'X_FORWARDED_FOR',
Request::HEADER_X_FORWARDED_HOST => 'X_FORWARDED_HOST',
Request::HEADER_X_FORWARDED_PORT => 'X_FORWARDED_PORT',
Request::HEADER_X_FORWARDED_PROTO => 'X_FORWARDED_PROTO',
];
}
+2 -2
View File
@@ -2,9 +2,9 @@
namespace App\Http\Middleware;
use Illuminate\Foundation\Http\Middleware\VerifyCsrfToken as BaseVerifier;
use Illuminate\Foundation\Http\Middleware\VerifyCsrfToken as Middleware;
class VerifyCsrfToken extends BaseVerifier
class VerifyCsrfToken extends Middleware
{
/**
* The URIs that should be excluded from CSRF verification.
+6 -2
View File
@@ -146,10 +146,10 @@
"scripts": {
"post-root-package-install": [
"php -r \"file_exists('.env') || copy('.env.example', '.env');\""
"@php -r \"file_exists('.env') || copy('.env.example', '.env');\""
],
"post-create-project-cmd": [
"php tmux key:generate"
"@php tmux key:generate"
],
"post-install-cmd": [
"nntmux\\build\\ComposerScripts::postInstall",
@@ -157,6 +157,10 @@
],
"post-update-cmd": [
"nntmux\\build\\ComposerScripts::postUpdate"
],
"post-autoload-dump": [
"Illuminate\\Foundation\\ComposerScripts::postAutoloadDump",
"@php tmux package:discover"
]
},
"suggest": {