style: run php-cs-fixer

This commit is contained in:
Bruno F. Fontes 2021-05-20 20:37:35 -03:00
parent 92a6410321
commit 54efb095fe
43 changed files with 84 additions and 102 deletions

View File

@ -3,13 +3,10 @@
namespace App\Events;
use \App\Item;
use Illuminate\Broadcasting\Channel;
use Illuminate\Queue\SerializesModels;
use Illuminate\Broadcasting\PrivateChannel;
use Illuminate\Broadcasting\PresenceChannel;
use Illuminate\Foundation\Events\Dispatchable;
use Illuminate\Broadcasting\InteractsWithSockets;
use Illuminate\Contracts\Broadcasting\ShouldBroadcast;
use Illuminate\Broadcasting\PrivateChannel;
use Illuminate\Foundation\Events\Dispatchable;
use Illuminate\Queue\SerializesModels;
class ReturnItem
{

View File

@ -3,8 +3,8 @@
namespace App\Exceptions;
use Exception;
Use Throwable;
use Illuminate\Foundation\Exceptions\Handler as ExceptionHandler;
use Throwable;
class Handler extends ExceptionHandler
{

View File

@ -2,12 +2,12 @@
namespace App\Http\Controllers;
use Auth;
use Mail;
use \App\Mail\UserWaiting;
use \App\User;
use App\FlashMessage;
use \App\Mail\UserWaiting;
use Auth;
use Illuminate\Http\Request;
use Mail;
class AlertController extends Controller
{

View File

@ -2,13 +2,13 @@
namespace App\Http\Controllers\Auth;
use App\User;
use App\Mail\Welcome;
use App\FlashMessage;
use App\Http\Controllers\Controller;
use App\Mail\Welcome;
use App\User;
use Illuminate\Foundation\Auth\RegistersUsers;
use Illuminate\Support\Facades\Hash;
use Illuminate\Support\Facades\Validator;
use Illuminate\Foundation\Auth\RegistersUsers;
use App\FlashMessage;
use Mail;
class RegisterController extends Controller

View File

@ -2,10 +2,10 @@
namespace App\Http\Controllers;
use Illuminate\Foundation\Bus\DispatchesJobs;
use Illuminate\Routing\Controller as BaseController;
use Illuminate\Foundation\Validation\ValidatesRequests;
use Illuminate\Foundation\Auth\Access\AuthorizesRequests;
use Illuminate\Foundation\Bus\DispatchesJobs;
use Illuminate\Foundation\Validation\ValidatesRequests;
use Illuminate\Routing\Controller as BaseController;
class Controller extends BaseController
{

View File

@ -4,8 +4,8 @@ namespace App\Http\Controllers;
use \App\Item;
use \App\User;
use Illuminate\Http\Request;
use App\FlashMessage as flash;
use Illuminate\Http\Request;
class ItemController extends Controller
{
@ -13,7 +13,8 @@ class ItemController extends Controller
{
$item = Item::find($id);
if (!$item || $item->product->user_id != \Auth::id()) {
session()->flash(flash::DANGER,
session()->flash(
flash::DANGER,
\Lang::getFromJson(
"The item doesn't exist."
)

View File

@ -3,7 +3,6 @@
namespace App\Http\Controllers;
use App;
use Lang;
use App\User;
use Illuminate\Http\Request;

View File

@ -3,10 +3,10 @@
namespace App\Http\Controllers;
use \App\Item;
use \App\User;
use \App\Product;
use Illuminate\Http\Request;
use \App\User;
use App\FlashMessage as flash;
use Illuminate\Http\Request;
class ProductController extends Controller
{

View File

@ -2,13 +2,11 @@
namespace App\Http\Controllers;
use Auth;
use Lang;
use App\Events\ReturnItem;
use App\Item;
use App\User;
use App\Events\ReturnItem;
use Illuminate\Http\Request;
use PhpParser\Node\Stmt\TryCatch;
use Lang;
/**
* Responsible to Take and Return an Item.
@ -51,7 +49,6 @@ class TakeController extends Controller
try {
$item->returnItem();
} catch (\Exception $e) {
return back()->withErrors(
Lang::getFromJson("You cannot return an item that is not with you")

View File

@ -2,10 +2,9 @@
namespace App\Http\Controllers;
use \Lang;
use \App\User;
use \App\Item;
use \App\Product;
use \App\User;
use \Lang;
use Illuminate\Http\Request;
class UserController extends Controller

View File

@ -2,8 +2,8 @@
namespace App\Http\Middleware;
use Illuminate\Http\Request;
use Fideloper\Proxy\TrustProxies as Middleware;
use Illuminate\Http\Request;
class TrustProxies extends Middleware
{

View File

@ -3,9 +3,8 @@
namespace App;
use Auth;
use Lang;
use Illuminate\Database\Eloquent\Model;
use Exception;
use Illuminate\Database\Eloquent\Model;
class Item extends Model
{

View File

@ -2,12 +2,10 @@
namespace App\Listeners;
use Mail;
use App\User;
use App\Events\ReturnItem;
use App\Mail\ItemAvailable;
use Illuminate\Queue\InteractsWithQueue;
use Illuminate\Contracts\Queue\ShouldQueue;
use App\User;
use Mail;
class AlertReturnedItem
{

View File

@ -3,10 +3,8 @@
namespace App\Listeners;
use App\User;
use IlluminateAuthEventsLogin;
use Illuminate\Queue\InteractsWithQueue;
use Illuminate\Contracts\Queue\ShouldQueue;
use Illuminate\Auth\Events\Login;
use IlluminateAuthEventsLogin;
class SetLanguage
{

View File

@ -6,7 +6,6 @@ use \App\Item;
use Illuminate\Bus\Queueable;
use Illuminate\Mail\Mailable;
use Illuminate\Queue\SerializesModels;
use Illuminate\Contracts\Queue\ShouldQueue;
class ItemAvailable extends Mailable
{

View File

@ -2,12 +2,11 @@
namespace App\Mail;
use Lang;
use \App\Item;
use Illuminate\Bus\Queueable;
use Illuminate\Mail\Mailable;
use Illuminate\Queue\SerializesModels;
use Illuminate\Contracts\Queue\ShouldQueue;
use Lang;
class UserWaiting extends Mailable
{

View File

@ -2,12 +2,11 @@
namespace App\Mail;
use \Lang;
use \App\User;
use \Lang;
use Illuminate\Bus\Queueable;
use Illuminate\Mail\Mailable;
use Illuminate\Queue\SerializesModels;
use Illuminate\Contracts\Queue\ShouldQueue;
class Welcome extends Mailable
{

View File

@ -2,8 +2,8 @@
namespace App\Providers;
use Illuminate\Support\ServiceProvider;
use Illuminate\Support\Facades\Schema;
use Illuminate\Support\ServiceProvider;
class AppServiceProvider extends ServiceProvider
{

View File

@ -2,7 +2,6 @@
namespace App\Providers;
use Illuminate\Support\Facades\Gate;
use Illuminate\Foundation\Support\Providers\AuthServiceProvider as ServiceProvider;
class AuthServiceProvider extends ServiceProvider

View File

@ -2,8 +2,8 @@
namespace App\Providers;
use Illuminate\Support\ServiceProvider;
use Illuminate\Support\Facades\Broadcast;
use Illuminate\Support\ServiceProvider;
class BroadcastServiceProvider extends ServiceProvider
{

View File

@ -3,12 +3,12 @@
namespace App\Providers;
use App\Events\ReturnItem;
use App\Listeners\SetLanguage;
use App\Listeners\AlertReturnedItem;
use Illuminate\Support\Facades\Event;
use App\Listeners\SetLanguage;
use Illuminate\Auth\Events\Registered;
use Illuminate\Auth\Listeners\SendEmailVerificationNotification;
use Illuminate\Foundation\Support\Providers\EventServiceProvider as ServiceProvider;
use Illuminate\Support\Facades\Event;
class EventServiceProvider extends ServiceProvider
{

View File

@ -2,8 +2,8 @@
namespace App\Providers;
use Illuminate\Support\Facades\Route;
use Illuminate\Foundation\Support\Providers\RouteServiceProvider as ServiceProvider;
use Illuminate\Support\Facades\Route;
class RouteServiceProvider extends ServiceProvider
{

View File

@ -3,10 +3,9 @@
namespace App;
use Auth;
use Illuminate\Notifications\Notifiable;
use Illuminate\Contracts\Auth\MustVerifyEmail;
use Illuminate\Foundation\Auth\User as Authenticatable;
use Illuminate\Support\Facades\Request;
use Illuminate\Notifications\Notifiable;
class User extends Authenticatable implements MustVerifyEmail
{

View File

@ -1,8 +1,8 @@
<?php
use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
class CreateUsersTable extends Migration
{

View File

@ -1,8 +1,8 @@
<?php
use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
class CreatePasswordResetsTable extends Migration
{

View File

@ -1,8 +1,8 @@
<?php
use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
class CreateProductsTable extends Migration
{

View File

@ -1,8 +1,8 @@
<?php
use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
class CreateItemsTable extends Migration
{

View File

@ -1,8 +1,8 @@
<?php
use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
class AddLocationToUsers extends Migration
{

View File

@ -3,8 +3,8 @@
namespace Tests\Feature;
use \App\Product;
use Tests\TestCase;
use Illuminate\Foundation\Testing\RefreshDatabase;
use Tests\TestCase;
class ExampleTest extends TestCase
{

View File

@ -3,7 +3,6 @@
namespace Tests\Unit;
use Tests\TestCase;
use Illuminate\Foundation\Testing\RefreshDatabase;
class ExampleTest extends TestCase
{