phpcs
This commit is contained in:
parent
87998c6a9a
commit
9b4d3ca1a3
36 changed files with 947 additions and 595 deletions
|
|
@ -15,7 +15,6 @@ class Kernel extends ConsoleKernel
|
||||||
*/
|
*/
|
||||||
protected function schedule(Schedule $schedule)
|
protected function schedule(Schedule $schedule)
|
||||||
{
|
{
|
||||||
// $schedule->command('inspire')->hourly();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
@ -25,7 +24,7 @@ class Kernel extends ConsoleKernel
|
||||||
*/
|
*/
|
||||||
protected function commands()
|
protected function commands()
|
||||||
{
|
{
|
||||||
$this->load(__DIR__.'/Commands');
|
$this->load(__DIR__ . '/Commands');
|
||||||
|
|
||||||
require base_path('routes/console.php');
|
require base_path('routes/console.php');
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -13,7 +13,6 @@ class Handler extends ExceptionHandler
|
||||||
* @var array<int, class-string<Throwable>>
|
* @var array<int, class-string<Throwable>>
|
||||||
*/
|
*/
|
||||||
protected $dontReport = [
|
protected $dontReport = [
|
||||||
//
|
|
||||||
];
|
];
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
@ -35,7 +34,6 @@ class Handler extends ExceptionHandler
|
||||||
public function register()
|
public function register()
|
||||||
{
|
{
|
||||||
$this->reportable(function (Throwable $e) {
|
$this->reportable(function (Throwable $e) {
|
||||||
//
|
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -9,5 +9,7 @@ use Illuminate\Routing\Controller as BaseController;
|
||||||
|
|
||||||
class Controller extends BaseController
|
class Controller extends BaseController
|
||||||
{
|
{
|
||||||
use AuthorizesRequests, DispatchesJobs, ValidatesRequests;
|
use AuthorizesRequests;
|
||||||
|
use DispatchesJobs;
|
||||||
|
use ValidatesRequests;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -14,6 +14,7 @@ class Kernel extends HttpKernel
|
||||||
* @var array<int, class-string|string>
|
* @var array<int, class-string|string>
|
||||||
*/
|
*/
|
||||||
protected $middleware = [
|
protected $middleware = [
|
||||||
|
// phpcs:ignore
|
||||||
// \App\Http\Middleware\TrustHosts::class,
|
// \App\Http\Middleware\TrustHosts::class,
|
||||||
\App\Http\Middleware\TrustProxies::class,
|
\App\Http\Middleware\TrustProxies::class,
|
||||||
\Fruitcake\Cors\HandleCors::class,
|
\Fruitcake\Cors\HandleCors::class,
|
||||||
|
|
@ -33,6 +34,7 @@ class Kernel extends HttpKernel
|
||||||
\App\Http\Middleware\EncryptCookies::class,
|
\App\Http\Middleware\EncryptCookies::class,
|
||||||
\Illuminate\Cookie\Middleware\AddQueuedCookiesToResponse::class,
|
\Illuminate\Cookie\Middleware\AddQueuedCookiesToResponse::class,
|
||||||
\Illuminate\Session\Middleware\StartSession::class,
|
\Illuminate\Session\Middleware\StartSession::class,
|
||||||
|
// phpcs:ignore
|
||||||
// \Illuminate\Session\Middleware\AuthenticateSession::class,
|
// \Illuminate\Session\Middleware\AuthenticateSession::class,
|
||||||
\Illuminate\View\Middleware\ShareErrorsFromSession::class,
|
\Illuminate\View\Middleware\ShareErrorsFromSession::class,
|
||||||
\App\Http\Middleware\VerifyCsrfToken::class,
|
\App\Http\Middleware\VerifyCsrfToken::class,
|
||||||
|
|
@ -40,7 +42,6 @@ class Kernel extends HttpKernel
|
||||||
],
|
],
|
||||||
|
|
||||||
'api' => [
|
'api' => [
|
||||||
// \Laravel\Sanctum\Http\Middleware\EnsureFrontendRequestsAreStateful::class,
|
|
||||||
'throttle:api',
|
'throttle:api',
|
||||||
\Illuminate\Routing\Middleware\SubstituteBindings::class,
|
\Illuminate\Routing\Middleware\SubstituteBindings::class,
|
||||||
],
|
],
|
||||||
|
|
|
||||||
|
|
@ -11,6 +11,7 @@ class Authenticate extends Middleware
|
||||||
*
|
*
|
||||||
* @param \Illuminate\Http\Request $request
|
* @param \Illuminate\Http\Request $request
|
||||||
* @return string|null
|
* @return string|null
|
||||||
|
* @phpcs:disable Squiz.Commenting.FunctionComment.TypeHintMissing
|
||||||
*/
|
*/
|
||||||
protected function redirectTo($request)
|
protected function redirectTo($request)
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -12,6 +12,5 @@ class EncryptCookies extends Middleware
|
||||||
* @var array<int, string>
|
* @var array<int, string>
|
||||||
*/
|
*/
|
||||||
protected $except = [
|
protected $except = [
|
||||||
//
|
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -12,6 +12,5 @@ class PreventRequestsDuringMaintenance extends Middleware
|
||||||
* @var array<int, string>
|
* @var array<int, string>
|
||||||
*/
|
*/
|
||||||
protected $except = [
|
protected $except = [
|
||||||
//
|
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -13,7 +13,7 @@ class RedirectIfAuthenticated
|
||||||
* Handle an incoming request.
|
* Handle an incoming request.
|
||||||
*
|
*
|
||||||
* @param \Illuminate\Http\Request $request
|
* @param \Illuminate\Http\Request $request
|
||||||
* @param \Closure(\Illuminate\Http\Request): (\Illuminate\Http\Response|\Illuminate\Http\RedirectResponse) $next
|
* @param \Closure $next
|
||||||
* @param string|null ...$guards
|
* @param string|null ...$guards
|
||||||
* @return \Illuminate\Http\Response|\Illuminate\Http\RedirectResponse
|
* @return \Illuminate\Http\Response|\Illuminate\Http\RedirectResponse
|
||||||
*/
|
*/
|
||||||
|
|
|
||||||
|
|
@ -17,7 +17,7 @@ class TrustProxies extends Middleware
|
||||||
/**
|
/**
|
||||||
* The headers that should be used to detect proxies.
|
* The headers that should be used to detect proxies.
|
||||||
*
|
*
|
||||||
* @var int
|
* @var integer
|
||||||
*/
|
*/
|
||||||
protected $headers =
|
protected $headers =
|
||||||
Request::HEADER_X_FORWARDED_FOR |
|
Request::HEADER_X_FORWARDED_FOR |
|
||||||
|
|
|
||||||
|
|
@ -12,6 +12,5 @@ class VerifyCsrfToken extends Middleware
|
||||||
* @var array<int, string>
|
* @var array<int, string>
|
||||||
*/
|
*/
|
||||||
protected $except = [
|
protected $except = [
|
||||||
//
|
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,6 @@
|
||||||
|
|
||||||
namespace App\Models;
|
namespace App\Models;
|
||||||
|
|
||||||
use Illuminate\Contracts\Auth\MustVerifyEmail;
|
|
||||||
use Illuminate\Database\Eloquent\Factories\HasFactory;
|
use Illuminate\Database\Eloquent\Factories\HasFactory;
|
||||||
use Illuminate\Foundation\Auth\User as Authenticatable;
|
use Illuminate\Foundation\Auth\User as Authenticatable;
|
||||||
use Illuminate\Notifications\Notifiable;
|
use Illuminate\Notifications\Notifiable;
|
||||||
|
|
@ -10,7 +9,9 @@ use Laravel\Sanctum\HasApiTokens;
|
||||||
|
|
||||||
class User extends Authenticatable
|
class User extends Authenticatable
|
||||||
{
|
{
|
||||||
use HasApiTokens, HasFactory, Notifiable;
|
use HasApiTokens;
|
||||||
|
use HasFactory;
|
||||||
|
use Notifiable;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The attributes that are mass assignable.
|
* The attributes that are mass assignable.
|
||||||
|
|
|
||||||
|
|
@ -13,7 +13,6 @@ class AppServiceProvider extends ServiceProvider
|
||||||
*/
|
*/
|
||||||
public function register()
|
public function register()
|
||||||
{
|
{
|
||||||
//
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
@ -23,6 +22,5 @@ class AppServiceProvider extends ServiceProvider
|
||||||
*/
|
*/
|
||||||
public function boot()
|
public function boot()
|
||||||
{
|
{
|
||||||
//
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,6 @@
|
||||||
namespace App\Providers;
|
namespace App\Providers;
|
||||||
|
|
||||||
use Illuminate\Foundation\Support\Providers\AuthServiceProvider as ServiceProvider;
|
use Illuminate\Foundation\Support\Providers\AuthServiceProvider as ServiceProvider;
|
||||||
use Illuminate\Support\Facades\Gate;
|
|
||||||
|
|
||||||
class AuthServiceProvider extends ServiceProvider
|
class AuthServiceProvider extends ServiceProvider
|
||||||
{
|
{
|
||||||
|
|
@ -12,9 +11,7 @@ class AuthServiceProvider extends ServiceProvider
|
||||||
*
|
*
|
||||||
* @var array<class-string, class-string>
|
* @var array<class-string, class-string>
|
||||||
*/
|
*/
|
||||||
protected $policies = [
|
protected $policies = [];
|
||||||
// 'App\Models\Model' => 'App\Policies\ModelPolicy',
|
|
||||||
];
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Register any authentication / authorization services.
|
* Register any authentication / authorization services.
|
||||||
|
|
@ -24,7 +21,5 @@ class AuthServiceProvider extends ServiceProvider
|
||||||
public function boot()
|
public function boot()
|
||||||
{
|
{
|
||||||
$this->registerPolicies();
|
$this->registerPolicies();
|
||||||
|
|
||||||
//
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -5,7 +5,6 @@ namespace App\Providers;
|
||||||
use Illuminate\Auth\Events\Registered;
|
use Illuminate\Auth\Events\Registered;
|
||||||
use Illuminate\Auth\Listeners\SendEmailVerificationNotification;
|
use Illuminate\Auth\Listeners\SendEmailVerificationNotification;
|
||||||
use Illuminate\Foundation\Support\Providers\EventServiceProvider as ServiceProvider;
|
use Illuminate\Foundation\Support\Providers\EventServiceProvider as ServiceProvider;
|
||||||
use Illuminate\Support\Facades\Event;
|
|
||||||
|
|
||||||
class EventServiceProvider extends ServiceProvider
|
class EventServiceProvider extends ServiceProvider
|
||||||
{
|
{
|
||||||
|
|
@ -27,6 +26,5 @@ class EventServiceProvider extends ServiceProvider
|
||||||
*/
|
*/
|
||||||
public function boot()
|
public function boot()
|
||||||
{
|
{
|
||||||
//
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -16,15 +16,6 @@ class RouteServiceProvider extends ServiceProvider
|
||||||
*/
|
*/
|
||||||
public const HOME = '/home';
|
public const HOME = '/home';
|
||||||
|
|
||||||
/**
|
|
||||||
* The controller namespace for the application.
|
|
||||||
*
|
|
||||||
* When present, controller route declarations will automatically be prefixed with this namespace.
|
|
||||||
*
|
|
||||||
* @var string|null
|
|
||||||
*/
|
|
||||||
// protected $namespace = 'App\\Http\\Controllers';
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Define your route model bindings, pattern filters, etc.
|
* Define your route model bindings, pattern filters, etc.
|
||||||
*
|
*
|
||||||
|
|
|
||||||
|
|
@ -13,7 +13,8 @@
|
||||||
"laravel/framework": "^8.75",
|
"laravel/framework": "^8.75",
|
||||||
"laravel/tinker": "^2.5",
|
"laravel/tinker": "^2.5",
|
||||||
"ldc/web-admin-secure-laravel": "1.0.1",
|
"ldc/web-admin-secure-laravel": "1.0.1",
|
||||||
"ldc/web-status-checker-laravel": "1.0.3"
|
"ldc/web-status-checker-laravel": "1.0.3",
|
||||||
|
"slevomat/coding-standard": "^8.3"
|
||||||
},
|
},
|
||||||
"require-dev": {
|
"require-dev": {
|
||||||
"facade/ignition": "^2.5",
|
"facade/ignition": "^2.5",
|
||||||
|
|
@ -58,7 +59,10 @@
|
||||||
"config": {
|
"config": {
|
||||||
"optimize-autoloader": true,
|
"optimize-autoloader": true,
|
||||||
"preferred-install": "dist",
|
"preferred-install": "dist",
|
||||||
"sort-packages": true
|
"sort-packages": true,
|
||||||
|
"allow-plugins": {
|
||||||
|
"dealerdirect/phpcodesniffer-composer-installer": true
|
||||||
|
}
|
||||||
},
|
},
|
||||||
"minimum-stability": "dev",
|
"minimum-stability": "dev",
|
||||||
"prefer-stable": true,
|
"prefer-stable": true,
|
||||||
|
|
|
||||||
239
composer.lock
generated
239
composer.lock
generated
|
|
@ -4,7 +4,7 @@
|
||||||
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
|
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
|
||||||
"This file is @generated automatically"
|
"This file is @generated automatically"
|
||||||
],
|
],
|
||||||
"content-hash": "7ffd89a71862ea45b9c1e28724296864",
|
"content-hash": "20dc62189c2b28a95116bb27cde6a040",
|
||||||
"packages": [
|
"packages": [
|
||||||
{
|
{
|
||||||
"name": "asm89/stack-cors",
|
"name": "asm89/stack-cors",
|
||||||
|
|
@ -122,6 +122,81 @@
|
||||||
],
|
],
|
||||||
"time": "2021-08-15T20:50:18+00:00"
|
"time": "2021-08-15T20:50:18+00:00"
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"name": "dealerdirect/phpcodesniffer-composer-installer",
|
||||||
|
"version": "v0.7.2",
|
||||||
|
"source": {
|
||||||
|
"type": "git",
|
||||||
|
"url": "https://github.com/Dealerdirect/phpcodesniffer-composer-installer.git",
|
||||||
|
"reference": "1c968e542d8843d7cd71de3c5c9c3ff3ad71a1db"
|
||||||
|
},
|
||||||
|
"dist": {
|
||||||
|
"type": "zip",
|
||||||
|
"url": "https://api.github.com/repos/Dealerdirect/phpcodesniffer-composer-installer/zipball/1c968e542d8843d7cd71de3c5c9c3ff3ad71a1db",
|
||||||
|
"reference": "1c968e542d8843d7cd71de3c5c9c3ff3ad71a1db",
|
||||||
|
"shasum": ""
|
||||||
|
},
|
||||||
|
"require": {
|
||||||
|
"composer-plugin-api": "^1.0 || ^2.0",
|
||||||
|
"php": ">=5.3",
|
||||||
|
"squizlabs/php_codesniffer": "^2.0 || ^3.1.0 || ^4.0"
|
||||||
|
},
|
||||||
|
"require-dev": {
|
||||||
|
"composer/composer": "*",
|
||||||
|
"php-parallel-lint/php-parallel-lint": "^1.3.1",
|
||||||
|
"phpcompatibility/php-compatibility": "^9.0"
|
||||||
|
},
|
||||||
|
"type": "composer-plugin",
|
||||||
|
"extra": {
|
||||||
|
"class": "Dealerdirect\\Composer\\Plugin\\Installers\\PHPCodeSniffer\\Plugin"
|
||||||
|
},
|
||||||
|
"autoload": {
|
||||||
|
"psr-4": {
|
||||||
|
"Dealerdirect\\Composer\\Plugin\\Installers\\PHPCodeSniffer\\": "src/"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"notification-url": "https://packagist.org/downloads/",
|
||||||
|
"license": [
|
||||||
|
"MIT"
|
||||||
|
],
|
||||||
|
"authors": [
|
||||||
|
{
|
||||||
|
"name": "Franck Nijhof",
|
||||||
|
"email": "franck.nijhof@dealerdirect.com",
|
||||||
|
"homepage": "http://www.frenck.nl",
|
||||||
|
"role": "Developer / IT Manager"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "Contributors",
|
||||||
|
"homepage": "https://github.com/Dealerdirect/phpcodesniffer-composer-installer/graphs/contributors"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"description": "PHP_CodeSniffer Standards Composer Installer Plugin",
|
||||||
|
"homepage": "http://www.dealerdirect.com",
|
||||||
|
"keywords": [
|
||||||
|
"PHPCodeSniffer",
|
||||||
|
"PHP_CodeSniffer",
|
||||||
|
"code quality",
|
||||||
|
"codesniffer",
|
||||||
|
"composer",
|
||||||
|
"installer",
|
||||||
|
"phpcbf",
|
||||||
|
"phpcs",
|
||||||
|
"plugin",
|
||||||
|
"qa",
|
||||||
|
"quality",
|
||||||
|
"standard",
|
||||||
|
"standards",
|
||||||
|
"style guide",
|
||||||
|
"stylecheck",
|
||||||
|
"tests"
|
||||||
|
],
|
||||||
|
"support": {
|
||||||
|
"issues": "https://github.com/dealerdirect/phpcodesniffer-composer-installer/issues",
|
||||||
|
"source": "https://github.com/dealerdirect/phpcodesniffer-composer-installer"
|
||||||
|
},
|
||||||
|
"time": "2022-02-04T12:51:07+00:00"
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"name": "doctrine/inflector",
|
"name": "doctrine/inflector",
|
||||||
"version": "2.0.4",
|
"version": "2.0.4",
|
||||||
|
|
@ -2374,6 +2449,51 @@
|
||||||
],
|
],
|
||||||
"time": "2022-07-30T15:51:26+00:00"
|
"time": "2022-07-30T15:51:26+00:00"
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"name": "phpstan/phpdoc-parser",
|
||||||
|
"version": "1.6.4",
|
||||||
|
"source": {
|
||||||
|
"type": "git",
|
||||||
|
"url": "https://github.com/phpstan/phpdoc-parser.git",
|
||||||
|
"reference": "135607f9ccc297d6923d49c2bcf309f509413215"
|
||||||
|
},
|
||||||
|
"dist": {
|
||||||
|
"type": "zip",
|
||||||
|
"url": "https://api.github.com/repos/phpstan/phpdoc-parser/zipball/135607f9ccc297d6923d49c2bcf309f509413215",
|
||||||
|
"reference": "135607f9ccc297d6923d49c2bcf309f509413215",
|
||||||
|
"shasum": ""
|
||||||
|
},
|
||||||
|
"require": {
|
||||||
|
"php": "^7.2 || ^8.0"
|
||||||
|
},
|
||||||
|
"require-dev": {
|
||||||
|
"php-parallel-lint/php-parallel-lint": "^1.2",
|
||||||
|
"phpstan/extension-installer": "^1.0",
|
||||||
|
"phpstan/phpstan": "^1.5",
|
||||||
|
"phpstan/phpstan-phpunit": "^1.1",
|
||||||
|
"phpstan/phpstan-strict-rules": "^1.0",
|
||||||
|
"phpunit/phpunit": "^9.5",
|
||||||
|
"symfony/process": "^5.2"
|
||||||
|
},
|
||||||
|
"type": "library",
|
||||||
|
"autoload": {
|
||||||
|
"psr-4": {
|
||||||
|
"PHPStan\\PhpDocParser\\": [
|
||||||
|
"src/"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"notification-url": "https://packagist.org/downloads/",
|
||||||
|
"license": [
|
||||||
|
"MIT"
|
||||||
|
],
|
||||||
|
"description": "PHPDoc parser with support for nullable, intersection and generic types",
|
||||||
|
"support": {
|
||||||
|
"issues": "https://github.com/phpstan/phpdoc-parser/issues",
|
||||||
|
"source": "https://github.com/phpstan/phpdoc-parser/tree/1.6.4"
|
||||||
|
},
|
||||||
|
"time": "2022-06-26T13:09:08+00:00"
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"name": "psr/container",
|
"name": "psr/container",
|
||||||
"version": "1.1.1",
|
"version": "1.1.1",
|
||||||
|
|
@ -2975,6 +3095,67 @@
|
||||||
],
|
],
|
||||||
"time": "2021-09-25T23:10:38+00:00"
|
"time": "2021-09-25T23:10:38+00:00"
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"name": "slevomat/coding-standard",
|
||||||
|
"version": "8.3.0",
|
||||||
|
"source": {
|
||||||
|
"type": "git",
|
||||||
|
"url": "https://github.com/slevomat/coding-standard.git",
|
||||||
|
"reference": "a14df437f2efe861ca9118508f304de9655957e4"
|
||||||
|
},
|
||||||
|
"dist": {
|
||||||
|
"type": "zip",
|
||||||
|
"url": "https://api.github.com/repos/slevomat/coding-standard/zipball/a14df437f2efe861ca9118508f304de9655957e4",
|
||||||
|
"reference": "a14df437f2efe861ca9118508f304de9655957e4",
|
||||||
|
"shasum": ""
|
||||||
|
},
|
||||||
|
"require": {
|
||||||
|
"dealerdirect/phpcodesniffer-composer-installer": "^0.6.2 || ^0.7",
|
||||||
|
"php": "^7.2 || ^8.0",
|
||||||
|
"phpstan/phpdoc-parser": "^1.6.2",
|
||||||
|
"squizlabs/php_codesniffer": "^3.7.1"
|
||||||
|
},
|
||||||
|
"require-dev": {
|
||||||
|
"phing/phing": "2.17.4",
|
||||||
|
"php-parallel-lint/php-parallel-lint": "1.3.2",
|
||||||
|
"phpstan/phpstan": "1.4.10|1.8.1",
|
||||||
|
"phpstan/phpstan-deprecation-rules": "1.0.0",
|
||||||
|
"phpstan/phpstan-phpunit": "1.0.0|1.1.1",
|
||||||
|
"phpstan/phpstan-strict-rules": "1.3.0",
|
||||||
|
"phpunit/phpunit": "7.5.20|8.5.21|9.5.21"
|
||||||
|
},
|
||||||
|
"type": "phpcodesniffer-standard",
|
||||||
|
"extra": {
|
||||||
|
"branch-alias": {
|
||||||
|
"dev-master": "7.x-dev"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"autoload": {
|
||||||
|
"psr-4": {
|
||||||
|
"SlevomatCodingStandard\\": "SlevomatCodingStandard"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"notification-url": "https://packagist.org/downloads/",
|
||||||
|
"license": [
|
||||||
|
"MIT"
|
||||||
|
],
|
||||||
|
"description": "Slevomat Coding Standard for PHP_CodeSniffer complements Consistence Coding Standard by providing sniffs with additional checks.",
|
||||||
|
"support": {
|
||||||
|
"issues": "https://github.com/slevomat/coding-standard/issues",
|
||||||
|
"source": "https://github.com/slevomat/coding-standard/tree/8.3.0"
|
||||||
|
},
|
||||||
|
"funding": [
|
||||||
|
{
|
||||||
|
"url": "https://github.com/kukulich",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"url": "https://tidelift.com/funding/github/packagist/slevomat/coding-standard",
|
||||||
|
"type": "tidelift"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"time": "2022-07-16T11:59:39+00:00"
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"name": "spatie/browsershot",
|
"name": "spatie/browsershot",
|
||||||
"version": "3.40.2",
|
"version": "3.40.2",
|
||||||
|
|
@ -3400,6 +3581,62 @@
|
||||||
},
|
},
|
||||||
"time": "2020-11-09T15:54:21+00:00"
|
"time": "2020-11-09T15:54:21+00:00"
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"name": "squizlabs/php_codesniffer",
|
||||||
|
"version": "3.7.1",
|
||||||
|
"source": {
|
||||||
|
"type": "git",
|
||||||
|
"url": "https://github.com/squizlabs/PHP_CodeSniffer.git",
|
||||||
|
"reference": "1359e176e9307e906dc3d890bcc9603ff6d90619"
|
||||||
|
},
|
||||||
|
"dist": {
|
||||||
|
"type": "zip",
|
||||||
|
"url": "https://api.github.com/repos/squizlabs/PHP_CodeSniffer/zipball/1359e176e9307e906dc3d890bcc9603ff6d90619",
|
||||||
|
"reference": "1359e176e9307e906dc3d890bcc9603ff6d90619",
|
||||||
|
"shasum": ""
|
||||||
|
},
|
||||||
|
"require": {
|
||||||
|
"ext-simplexml": "*",
|
||||||
|
"ext-tokenizer": "*",
|
||||||
|
"ext-xmlwriter": "*",
|
||||||
|
"php": ">=5.4.0"
|
||||||
|
},
|
||||||
|
"require-dev": {
|
||||||
|
"phpunit/phpunit": "^4.0 || ^5.0 || ^6.0 || ^7.0"
|
||||||
|
},
|
||||||
|
"bin": [
|
||||||
|
"bin/phpcs",
|
||||||
|
"bin/phpcbf"
|
||||||
|
],
|
||||||
|
"type": "library",
|
||||||
|
"extra": {
|
||||||
|
"branch-alias": {
|
||||||
|
"dev-master": "3.x-dev"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"notification-url": "https://packagist.org/downloads/",
|
||||||
|
"license": [
|
||||||
|
"BSD-3-Clause"
|
||||||
|
],
|
||||||
|
"authors": [
|
||||||
|
{
|
||||||
|
"name": "Greg Sherwood",
|
||||||
|
"role": "lead"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"description": "PHP_CodeSniffer tokenizes PHP, JavaScript and CSS files and detects violations of a defined set of coding standards.",
|
||||||
|
"homepage": "https://github.com/squizlabs/PHP_CodeSniffer",
|
||||||
|
"keywords": [
|
||||||
|
"phpcs",
|
||||||
|
"standards"
|
||||||
|
],
|
||||||
|
"support": {
|
||||||
|
"issues": "https://github.com/squizlabs/PHP_CodeSniffer/issues",
|
||||||
|
"source": "https://github.com/squizlabs/PHP_CodeSniffer",
|
||||||
|
"wiki": "https://github.com/squizlabs/PHP_CodeSniffer/wiki"
|
||||||
|
},
|
||||||
|
"time": "2022-06-18T07:21:10+00:00"
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"name": "swiftmailer/swiftmailer",
|
"name": "swiftmailer/swiftmailer",
|
||||||
"version": "v6.3.0",
|
"version": "v6.3.0",
|
||||||
|
|
|
||||||
|
|
@ -39,7 +39,7 @@ return [
|
||||||
|
|
|
|
||||||
*/
|
*/
|
||||||
|
|
||||||
'debug' => (bool) env('APP_DEBUG', false),
|
'debug' => (bool)env('APP_DEBUG', false),
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|--------------------------------------------------------------------------
|
|--------------------------------------------------------------------------
|
||||||
|
|
@ -139,6 +139,7 @@ return [
|
||||||
/*
|
/*
|
||||||
* Laravel Framework Service Providers...
|
* Laravel Framework Service Providers...
|
||||||
*/
|
*/
|
||||||
|
|
||||||
Illuminate\Auth\AuthServiceProvider::class,
|
Illuminate\Auth\AuthServiceProvider::class,
|
||||||
Illuminate\Broadcasting\BroadcastServiceProvider::class,
|
Illuminate\Broadcasting\BroadcastServiceProvider::class,
|
||||||
Illuminate\Bus\BusServiceProvider::class,
|
Illuminate\Bus\BusServiceProvider::class,
|
||||||
|
|
@ -169,8 +170,10 @@ return [
|
||||||
/*
|
/*
|
||||||
* Application Service Providers...
|
* Application Service Providers...
|
||||||
*/
|
*/
|
||||||
|
|
||||||
App\Providers\AppServiceProvider::class,
|
App\Providers\AppServiceProvider::class,
|
||||||
App\Providers\AuthServiceProvider::class,
|
App\Providers\AuthServiceProvider::class,
|
||||||
|
// phpcs:ignore
|
||||||
// App\Providers\BroadcastServiceProvider::class,
|
// App\Providers\BroadcastServiceProvider::class,
|
||||||
App\Providers\EventServiceProvider::class,
|
App\Providers\EventServiceProvider::class,
|
||||||
App\Providers\RouteServiceProvider::class,
|
App\Providers\RouteServiceProvider::class,
|
||||||
|
|
@ -218,6 +221,7 @@ return [
|
||||||
'Queue' => Illuminate\Support\Facades\Queue::class,
|
'Queue' => Illuminate\Support\Facades\Queue::class,
|
||||||
'RateLimiter' => Illuminate\Support\Facades\RateLimiter::class,
|
'RateLimiter' => Illuminate\Support\Facades\RateLimiter::class,
|
||||||
'Redirect' => Illuminate\Support\Facades\Redirect::class,
|
'Redirect' => Illuminate\Support\Facades\Redirect::class,
|
||||||
|
// phpcs:ignore
|
||||||
// 'Redis' => Illuminate\Support\Facades\Redis::class,
|
// 'Redis' => Illuminate\Support\Facades\Redis::class,
|
||||||
'Request' => Illuminate\Support\Facades\Request::class,
|
'Request' => Illuminate\Support\Facades\Request::class,
|
||||||
'Response' => Illuminate\Support\Facades\Response::class,
|
'Response' => Illuminate\Support\Facades\Response::class,
|
||||||
|
|
|
||||||
|
|
@ -64,11 +64,6 @@ return [
|
||||||
'driver' => 'eloquent',
|
'driver' => 'eloquent',
|
||||||
'model' => App\Models\User::class,
|
'model' => App\Models\User::class,
|
||||||
],
|
],
|
||||||
|
|
||||||
// 'users' => [
|
|
||||||
// 'driver' => 'database',
|
|
||||||
// 'table' => 'users',
|
|
||||||
// ],
|
|
||||||
],
|
],
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|
|
||||||
|
|
@ -62,6 +62,7 @@ return [
|
||||||
env('MEMCACHED_PASSWORD'),
|
env('MEMCACHED_PASSWORD'),
|
||||||
],
|
],
|
||||||
'options' => [
|
'options' => [
|
||||||
|
// phpcs:ignore
|
||||||
// Memcached::OPT_CONNECT_TIMEOUT => 2000,
|
// Memcached::OPT_CONNECT_TIMEOUT => 2000,
|
||||||
],
|
],
|
||||||
'servers' => [
|
'servers' => [
|
||||||
|
|
@ -105,6 +106,6 @@ return [
|
||||||
|
|
|
|
||||||
*/
|
*/
|
||||||
|
|
||||||
'prefix' => env('CACHE_PREFIX', Str::slug(env('APP_NAME', 'laravel'), '_').'_cache'),
|
'prefix' => env('CACHE_PREFIX', Str::slug(env('APP_NAME', 'laravel'), '_') . '_cache'),
|
||||||
|
|
||||||
];
|
];
|
||||||
|
|
|
||||||
|
|
@ -123,7 +123,7 @@ return [
|
||||||
|
|
||||||
'options' => [
|
'options' => [
|
||||||
'cluster' => env('REDIS_CLUSTER', 'redis'),
|
'cluster' => env('REDIS_CLUSTER', 'redis'),
|
||||||
'prefix' => env('REDIS_PREFIX', Str::slug(env('APP_NAME', 'laravel'), '_').'_database_'),
|
'prefix' => env('REDIS_PREFIX', Str::slug(env('APP_NAME', 'laravel'), '_') . '_database_'),
|
||||||
],
|
],
|
||||||
|
|
||||||
'default' => [
|
'default' => [
|
||||||
|
|
|
||||||
|
|
@ -38,7 +38,7 @@ return [
|
||||||
'public' => [
|
'public' => [
|
||||||
'driver' => 'local',
|
'driver' => 'local',
|
||||||
'root' => storage_path('app/public'),
|
'root' => storage_path('app/public'),
|
||||||
'url' => env('APP_URL').'/storage',
|
'url' => env('APP_URL') . '/storage',
|
||||||
'visibility' => 'public',
|
'visibility' => 'public',
|
||||||
],
|
],
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -128,7 +128,7 @@ return [
|
||||||
|
|
||||||
'cookie' => env(
|
'cookie' => env(
|
||||||
'SESSION_COOKIE',
|
'SESSION_COOKIE',
|
||||||
Str::slug(env('APP_NAME', 'laravel'), '_').'_session'
|
Str::slug(env('APP_NAME', 'laravel'), '_') . '_session'
|
||||||
),
|
),
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|
|
||||||
|
|
@ -18,7 +18,7 @@ class UserFactory extends Factory
|
||||||
'name' => $this->faker->name(),
|
'name' => $this->faker->name(),
|
||||||
'email' => $this->faker->unique()->safeEmail(),
|
'email' => $this->faker->unique()->safeEmail(),
|
||||||
'email_verified_at' => now(),
|
'email_verified_at' => now(),
|
||||||
'password' => '$2y$10$92IXUNpkjO0rOQ5byMi.Ye4oKoEa3Ro9llC/.og/at2.uheWG/igi', // password
|
'password' => '$2y$10$92IXUNpkjO0rOQ5byMi.Ye4oKoEa3Ro9llC/.og/at2.uheWG/igi',
|
||||||
'remember_token' => Str::random(10),
|
'remember_token' => Str::random(10),
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|
@ -30,6 +30,7 @@ class UserFactory extends Factory
|
||||||
*/
|
*/
|
||||||
public function unverified()
|
public function unverified()
|
||||||
{
|
{
|
||||||
|
// phpcs:ignore
|
||||||
return $this->state(function (array $attributes) {
|
return $this->state(function (array $attributes) {
|
||||||
return [
|
return [
|
||||||
'email_verified_at' => null,
|
'email_verified_at' => null,
|
||||||
|
|
|
||||||
128
phpcs.xml
Normal file
128
phpcs.xml
Normal file
|
|
@ -0,0 +1,128 @@
|
||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<ruleset name="LDC Laravel"
|
||||||
|
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="vendor/squizlabs/php_codesniffer/phpcs.xsd">
|
||||||
|
<description>Created with the PHP Coding Standard Generator. http://edorian.github.com/php-coding-standard-generator/</description>
|
||||||
|
<arg name="colors" />
|
||||||
|
<arg name="extensions" value="php" />
|
||||||
|
<file>app/</file>
|
||||||
|
<file>config/</file>
|
||||||
|
<file>database/factories</file>
|
||||||
|
<file>routes/</file>
|
||||||
|
<rule ref="PSR1" />
|
||||||
|
<rule ref="PSR12" />
|
||||||
|
|
||||||
|
<rule ref="Generic.Classes.DuplicateClassName"/>
|
||||||
|
<rule ref="Generic.CodeAnalysis.EmptyStatement"/>
|
||||||
|
<rule ref="Generic.CodeAnalysis.ForLoopShouldBeWhileLoop"/>
|
||||||
|
<rule ref="Generic.CodeAnalysis.ForLoopWithTestFunctionCall"/>
|
||||||
|
<rule ref="Generic.CodeAnalysis.JumbledIncrementer"/>
|
||||||
|
<rule ref="Generic.CodeAnalysis.UnconditionalIfStatement"/>
|
||||||
|
<rule ref="Generic.CodeAnalysis.UnnecessaryFinalModifier"/>
|
||||||
|
<rule ref="Generic.CodeAnalysis.UnusedFunctionParameter"/>
|
||||||
|
<rule ref="Generic.CodeAnalysis.UselessOverridingMethod"/>
|
||||||
|
<rule ref="Generic.Commenting.Todo"/>
|
||||||
|
<rule ref="Generic.Commenting.Fixme"/>
|
||||||
|
<rule ref="Generic.ControlStructures.InlineControlStructure"/>
|
||||||
|
<rule ref="Generic.Files.ByteOrderMark"/>
|
||||||
|
<rule ref="Generic.Files.LineEndings"/>
|
||||||
|
<rule ref="Generic.Files.LineLength"/>
|
||||||
|
<rule ref="Generic.Formatting.DisallowMultipleStatements"/>
|
||||||
|
<rule ref="Generic.Formatting.MultipleStatementAlignment"/>
|
||||||
|
<rule ref="Generic.Formatting.NoSpaceAfterCast"/>
|
||||||
|
<rule ref="Generic.Functions.CallTimePassByReference"/>
|
||||||
|
<rule ref="Generic.Functions.FunctionCallArgumentSpacing"/>
|
||||||
|
<rule ref="Generic.Metrics.CyclomaticComplexity"/>
|
||||||
|
<rule ref="Generic.Metrics.NestingLevel"/>
|
||||||
|
<rule ref="Generic.NamingConventions.ConstructorName"/>
|
||||||
|
<rule ref="Generic.NamingConventions.UpperCaseConstantName"/>
|
||||||
|
<rule ref="Generic.NamingConventions.CamelCapsFunctionName"/>
|
||||||
|
<rule ref="Generic.PHP.DeprecatedFunctions"/>
|
||||||
|
<rule ref="Generic.PHP.DisallowShortOpenTag"/>
|
||||||
|
<rule ref="Generic.PHP.ForbiddenFunctions"/>
|
||||||
|
<rule ref="Generic.PHP.NoSilencedErrors"/>
|
||||||
|
<rule ref="Generic.Strings.UnnecessaryStringConcat"/>
|
||||||
|
<rule ref="Generic.WhiteSpace.DisallowTabIndent"/>
|
||||||
|
<rule ref="Generic.WhiteSpace.ScopeIndent"/>
|
||||||
|
<rule ref="MySource.PHP.EvalObjectFactory"/>
|
||||||
|
<rule ref="MySource.PHP.GetRequestData"/>
|
||||||
|
<rule ref="MySource.PHP.AjaxNullComparison"/>
|
||||||
|
<rule ref="PEAR.Classes.ClassDeclaration"/>
|
||||||
|
<rule ref="PEAR.Commenting.InlineComment"/>
|
||||||
|
<rule ref="PSR1.Classes.ClassDeclaration"/>
|
||||||
|
<rule ref="PSR1.Files.SideEffects"/>
|
||||||
|
<rule ref="PSR2.Classes.ClassDeclaration"/>
|
||||||
|
<rule ref="PSR2.Classes.PropertyDeclaration"/>
|
||||||
|
<rule ref="PSR2.ControlStructures.ElseIfDeclaration"/>
|
||||||
|
<rule ref="PSR2.ControlStructures.SwitchDeclaration"/>
|
||||||
|
<rule ref="PSR2.Files.EndFileNewline"/>
|
||||||
|
<rule ref="PSR2.Methods.MethodDeclaration"/>
|
||||||
|
<rule ref="PSR2.Namespaces.NamespaceDeclaration"/>
|
||||||
|
<rule ref="PSR2.Namespaces.UseDeclaration"/>
|
||||||
|
<rule ref="Squiz.PHP.CommentedOutCode"/>
|
||||||
|
<rule ref="Squiz.PHP.DisallowMultipleAssignments">
|
||||||
|
<exclude name="Squiz.PHP.DisallowMultipleAssignments.FoundInControlStructure" />
|
||||||
|
</rule>
|
||||||
|
<rule ref="Squiz.PHP.DisallowSizeFunctionsInLoops"/>
|
||||||
|
|
||||||
|
<rule ref="Squiz.PHP.DiscouragedFunctions">
|
||||||
|
<properties>
|
||||||
|
<property name="error" value="true"/>
|
||||||
|
</properties>
|
||||||
|
</rule>
|
||||||
|
<rule ref="Squiz.PHP.Eval"/>
|
||||||
|
<rule ref="Squiz.PHP.GlobalKeyword"/>
|
||||||
|
<rule ref="Squiz.PHP.Heredoc"/>
|
||||||
|
<rule ref="Squiz.PHP.InnerFunctions"/>
|
||||||
|
<rule ref="Squiz.PHP.LowercasePHPFunctions"/>
|
||||||
|
<rule ref="Squiz.PHP.NonExecutableCode"/>
|
||||||
|
<rule ref="Squiz.Scope.MemberVarScope"/>
|
||||||
|
<rule ref="Squiz.Scope.MethodScope"/>
|
||||||
|
<rule ref="Squiz.Scope.StaticThisUsage"/>
|
||||||
|
<rule ref="Squiz.WhiteSpace.LanguageConstructSpacing"/>
|
||||||
|
<rule ref="Squiz.WhiteSpace.LogicalOperatorSpacing"/>
|
||||||
|
<rule ref="Squiz.WhiteSpace.MemberVarSpacing">
|
||||||
|
<properties>
|
||||||
|
<property name="spacingBeforeFirst " value="false"/>
|
||||||
|
</properties>
|
||||||
|
</rule>
|
||||||
|
<rule ref="Squiz.WhiteSpace.OperatorSpacing">
|
||||||
|
<properties>
|
||||||
|
<property name="ignoreNewlines" value="true"/>
|
||||||
|
</properties>
|
||||||
|
</rule>
|
||||||
|
<rule ref="Squiz.WhiteSpace.ObjectOperatorSpacing">
|
||||||
|
<properties>
|
||||||
|
<property name="ignoreNewlines" value="true"/>
|
||||||
|
</properties>
|
||||||
|
</rule>
|
||||||
|
<rule ref="Squiz.WhiteSpace.ScopeKeywordSpacing"/>
|
||||||
|
<rule ref="Squiz.WhiteSpace.SemicolonSpacing"/>
|
||||||
|
<rule ref="Squiz.Commenting.BlockComment">
|
||||||
|
<exclude name="Squiz.Commenting.BlockComment.WrongStart" />
|
||||||
|
</rule>
|
||||||
|
<rule ref="Squiz.Commenting.ClassComment">
|
||||||
|
<exclude name="Squiz.Commenting.ClassComment.Missing" />
|
||||||
|
<exclude name="Squiz.Commenting.ClassComment.TagNotAllowed" />
|
||||||
|
</rule>
|
||||||
|
<rule ref="Squiz.Commenting.DocCommentAlignment"/>
|
||||||
|
<rule ref="Squiz.Commenting.EmptyCatchComment"/>
|
||||||
|
<rule ref="Squiz.Commenting.FunctionComment">
|
||||||
|
<exclude name="Squiz.Commenting.FunctionComment.MissingParamComment" />
|
||||||
|
</rule>
|
||||||
|
<rule ref="Squiz.Commenting.FunctionCommentThrowTag"/>
|
||||||
|
<rule ref="Squiz.Commenting.InlineComment">
|
||||||
|
<exclude name="Squiz.Commenting.InlineComment.DocBlock" />
|
||||||
|
</rule>
|
||||||
|
<rule ref="Squiz.Commenting.LongConditionClosingComment">
|
||||||
|
<exclude name="Squiz.Commenting.LongConditionClosingComment.SpacingBefore" />
|
||||||
|
</rule>
|
||||||
|
<rule ref="Squiz.Commenting.PostStatementComment"/>
|
||||||
|
<rule ref="Squiz.Commenting.VariableComment"/>
|
||||||
|
<rule ref="SlevomatCodingStandard.Namespaces.UnusedUses.UnusedUse" />
|
||||||
|
|
||||||
|
<!-- For Laravel migrations -->
|
||||||
|
<rule ref="PSR1.Classes.ClassDeclaration.MissingNamespace">
|
||||||
|
<exclude-pattern>*/database/migrations/*</exclude-pattern>
|
||||||
|
</rule>
|
||||||
|
|
||||||
|
</ruleset>
|
||||||
1
routes/console.php
Normal file
1
routes/console.php
Normal file
|
|
@ -0,0 +1 @@
|
||||||
|
<?php
|
||||||
|
|
@ -3,14 +3,14 @@
|
||||||
use Illuminate\Support\Facades\Route;
|
use Illuminate\Support\Facades\Route;
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|--------------------------------------------------------------------------
|
|--------------------------------------------------------------------------
|
||||||
| Web Routes
|
| Web Routes
|
||||||
|--------------------------------------------------------------------------
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
|
||||||
| Here is where you can register web routes for your application. These
|
| Here is where you can register web routes for your application. These
|
||||||
| routes are loaded by the RouteServiceProvider within a group which
|
| routes are loaded by the RouteServiceProvider within a group which
|
||||||
| contains the "web" middleware group. Now create something great!
|
| contains the "web" middleware group. Now create something great!
|
||||||
|
|
|
|
||||||
*/
|
*/
|
||||||
|
|
||||||
Route::prefix('bo')->name('bo')->middleware(['admin-secure'])->group(function () {
|
Route::prefix('bo')->name('bo')->middleware(['admin-secure'])->group(function () {
|
||||||
|
|
|
||||||
|
|
@ -3,14 +3,14 @@
|
||||||
use Illuminate\Support\Facades\Route;
|
use Illuminate\Support\Facades\Route;
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|--------------------------------------------------------------------------
|
|--------------------------------------------------------------------------
|
||||||
| Web Routes
|
| Web Routes
|
||||||
|--------------------------------------------------------------------------
|
|--------------------------------------------------------------------------
|
||||||
|
|
|
|
||||||
| Here is where you can register web routes for your application. These
|
| Here is where you can register web routes for your application. These
|
||||||
| routes are loaded by the RouteServiceProvider within a group which
|
| routes are loaded by the RouteServiceProvider within a group which
|
||||||
| contains the "web" middleware group. Now create something great!
|
| contains the "web" middleware group. Now create something great!
|
||||||
|
|
|
|
||||||
*/
|
*/
|
||||||
|
|
||||||
Route::get('/', function () {
|
Route::get('/', function () {
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue