Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/Acl/AccessManager.php
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ trait AccessManager
* @param int $role_id
* @return \Illuminate\Database\Eloquent\Builder|\Illuminate\Database\Eloquent\Collection
*/
public function getCompleteRole(int $role_id = null)
public function getCompleteRole(?int $role_id = null)
{

$roles = RoleModel::with('permissions', 'users');
Expand Down
2 changes: 1 addition & 1 deletion src/Http/Controllers/Character/MailController.php
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,7 @@ public function getMailTimelineRead(int $message_id)
* @param int $message_id
* @return mixed
*/
private function getCharacterMailTimeline(int $message_id = null)
private function getCharacterMailTimeline(?int $message_id = null)
{
// Get the User for permissions and affiliation
// checks
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ class MiningLedgerController extends Controller
* @param \Seat\Web\Http\DataTables\Corporation\Industrial\MiningDataTable $dataTable
* @return mixed
*/
public function index(CorporationInfo $corporation, MiningDataTable $dataTable, int $year = null, int $month = null)
public function index(CorporationInfo $corporation, MiningDataTable $dataTable, ?int $year = null, ?int $month = null)
{
if (is_null($year)) $year = carbon()->year;

Expand Down
8 changes: 4 additions & 4 deletions src/Http/Controllers/Squads/ApplicationsController.php
Original file line number Diff line number Diff line change
Expand Up @@ -64,8 +64,8 @@ public function show(Squad $squad, int $id)
*/
public function store(Request $request, Squad $squad)
{
if(!$squad->isUserEligible(auth()->user())) {
return redirect()->back()->with('error','You are not eligible for this squad!');
if(! $squad->isUserEligible(auth()->user())) {
return redirect()->back()->with('error', 'You are not eligible for this squad!');
}

// in case the squad is manual and does not contain any moderator
Expand Down Expand Up @@ -112,8 +112,8 @@ public function approve(Squad $squad, int $id)
{
$application = SquadApplication::with('squad', 'user')->find($id);

if(!$squad->isUserEligible($application->user)) {
return redirect()->back()->with('error','The applicant is not eligible for this squad!');
if(! $squad->isUserEligible($application->user)) {
return redirect()->back()->with('error', 'The applicant is not eligible for this squad!');
}

$squad->members()->save($application->user);
Expand Down