Skip to content

Commit

Permalink
code quality
Browse files Browse the repository at this point in the history
  • Loading branch information
dbarzin committed Mar 6, 2024
1 parent 36b8dae commit bcb96e6
Show file tree
Hide file tree
Showing 5 changed files with 5 additions and 8 deletions.
2 changes: 1 addition & 1 deletion app/Console/Commands/SendNotifications.php
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@ private function needCheck()
// Weekly
(($check_frequency === '7') && (Carbon::today()->dayOfWeek === 1)) ||
// Every two weeks
(($check_frequency === '15') && ((Carbon::today()->day === 1)||(Carbon::today()->day === 15))) ||
(($check_frequency === '15') && ((Carbon::today()->day === 1) || (Carbon::today()->day === 15))) ||
// Monthly
(($check_frequency === '30') && (Carbon::today()->day === 1));
}
Expand Down
6 changes: 2 additions & 4 deletions app/Exports/MeasuresExport.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,11 @@
use Maatwebsite\Excel\Concerns\WithHeadings;
use Maatwebsite\Excel\Concerns\WithMapping;
use Maatwebsite\Excel\Concerns\WithStyles;
use PhpOffice\PhpSpreadsheet\Cell\StringValueBinder;
use PhpOffice\PhpSpreadsheet\Style\NumberFormat;
use PhpOffice\PhpSpreadsheet\Worksheet\Worksheet;
use \PhpOffice\PhpSpreadsheet\Cell\StringValueBinder;

class MeasuresExport
extends StringValueBinder
implements FromQuery, WithMapping, WithHeadings, WithStyles, WithColumnWidths
class MeasuresExport extends StringValueBinder implements FromQuery, WithMapping, WithHeadings, WithStyles, WithColumnWidths
{
public function headings(): array
{
Expand Down
2 changes: 1 addition & 1 deletion app/Http/Controllers/ActionplanController.php
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ public function save(Request $request)
$control = Control::find($id);
$control->action_plan = request('action_plan');
$control->update();

// save next control
$next_id = $control->next_id;
$next_control = Control::find($next_id);
Expand Down
2 changes: 1 addition & 1 deletion app/Http/Controllers/GlobalSearchController.php
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ public function search(Request $request)
foreach ($this->models as $model) {
// user only search on controls
if (
(Auth::User()->role === 5) && ($model != 'App\\Models\\Control')
(Auth::User()->role === 5) && ($model !== 'App\\Models\\Control')
) {
continue;
}
Expand Down
1 change: 0 additions & 1 deletion app/Http/Controllers/UserController.php
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,6 @@ public function store(Request $request)
);

if (Config::get('app.ldap_domain') === null) {

$password = request('password1');

if ($password === null) {
Expand Down

0 comments on commit bcb96e6

Please sign in to comment.