mirror of
https://github.com/HDInnovations/UNIT3D-Community-Edition.git
synced 2026-02-11 22:19:47 -06:00
refactor: swap magic RedirectResponse withX('Y') to with('X', 'Y')
Allows ctrl+clicking to access the underlying function unlike the previous magic implementation. Probably also negligibly faster.
Swapped all instances of `>withSuccess(` -> `>with('success', `, `>withWarning(` -> `>with('warning', `, and `>withInfo(` -> `>with('info', ` with ide's find and replace.
This commit is contained in:
@@ -129,7 +129,7 @@ class InviteController extends Controller
|
||||
Mail::to($request->input('email'))->send(new InviteUser($invite));
|
||||
|
||||
return to_route('users.invites.create', ['user' => $user])
|
||||
->withSuccess(trans('user.invite-sent-success'));
|
||||
->with('success', trans('user.invite-sent-success'));
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -152,7 +152,7 @@ class InviteController extends Controller
|
||||
$sentInvite->delete();
|
||||
|
||||
return to_route('users.invites.index', ['user' => $user])
|
||||
->withSuccess('Invite deleted successfully.');
|
||||
->with('success', 'Invite deleted successfully.');
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -175,6 +175,6 @@ class InviteController extends Controller
|
||||
Mail::to($sentInvite->email)->send(new InviteUser($sentInvite));
|
||||
|
||||
return to_route('users.invites.index', ['user' => $user])
|
||||
->withSuccess(trans('user.invite-resent-success'));
|
||||
->with('success', trans('user.invite-resent-success'));
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user