Skip to content

Commit

Permalink
Apply fixes from StyleCI
Browse files Browse the repository at this point in the history
  • Loading branch information
StyleCIBot committed Feb 14, 2024
1 parent ad2d5d7 commit 44bee8c
Show file tree
Hide file tree
Showing 9 changed files with 15 additions and 19 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,7 @@
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;

return new class extends Migration
{
return new class() extends Migration {
/**
* Run the migrations.
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,7 @@
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;

return new class() extends Migration
{
return new class() extends Migration {
/**
* Run the migrations.
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,7 @@
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;

return new class() extends Migration
{
return new class() extends Migration {
/**
* Run the migrations.
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,7 @@
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;

return new class() extends Migration
{
return new class() extends Migration {
/**
* Run the migrations.
*/
Expand Down
4 changes: 2 additions & 2 deletions app/Filament/Exports/AircraftExporter.php
Original file line number Diff line number Diff line change
Expand Up @@ -35,10 +35,10 @@ public static function getColumns(): array

public static function getCompletedNotificationBody(Export $export): string
{
$body = 'Your aircraft export has completed and ' . number_format($export->successful_rows) . ' ' . str('row')->plural($export->successful_rows) . ' exported.';
$body = 'Your aircraft export has completed and '.number_format($export->successful_rows).' '.str('row')->plural($export->successful_rows).' exported.';

if ($failedRowsCount = $export->getFailedRowsCount()) {
$body .= ' ' . number_format($failedRowsCount) . ' ' . str('row')->plural($failedRowsCount) . ' failed to export.';
$body .= ' '.number_format($failedRowsCount).' '.str('row')->plural($failedRowsCount).' failed to export.';
}

return $body;
Expand Down
4 changes: 2 additions & 2 deletions app/Filament/Exports/AirportExporter.php
Original file line number Diff line number Diff line change
Expand Up @@ -35,10 +35,10 @@ public static function getColumns(): array

public static function getCompletedNotificationBody(Export $export): string
{
$body = 'Your airport export has completed and ' . number_format($export->successful_rows) . ' ' . str('row')->plural($export->successful_rows) . ' exported.';
$body = 'Your airport export has completed and '.number_format($export->successful_rows).' '.str('row')->plural($export->successful_rows).' exported.';

if ($failedRowsCount = $export->getFailedRowsCount()) {
$body .= ' ' . number_format($failedRowsCount) . ' ' . str('row')->plural($failedRowsCount) . ' failed to export.';
$body .= ' '.number_format($failedRowsCount).' '.str('row')->plural($failedRowsCount).' failed to export.';
}

return $body;
Expand Down
8 changes: 4 additions & 4 deletions app/Filament/Imports/AircraftImporter.php
Original file line number Diff line number Diff line change
Expand Up @@ -54,17 +54,17 @@ public static function getColumns(): array
public function resolveRecord(): ?Aircraft
{
return Aircraft::firstOrNew([
// Update existing records, matching them by `$this->data['column_name']`
'registration' => $this->data['registration'],
// Update existing records, matching them by `$this->data['column_name']`
'registration' => $this->data['registration'],
]);
}

public static function getCompletedNotificationBody(Import $import): string
{
$body = 'Your aircraft import has completed and ' . number_format($import->successful_rows) . ' ' . str('row')->plural($import->successful_rows) . ' imported.';
$body = 'Your aircraft import has completed and '.number_format($import->successful_rows).' '.str('row')->plural($import->successful_rows).' imported.';

if ($failedRowsCount = $import->getFailedRowsCount()) {
$body .= ' ' . number_format($failedRowsCount) . ' ' . str('row')->plural($failedRowsCount) . ' failed to import.';
$body .= ' '.number_format($failedRowsCount).' '.str('row')->plural($failedRowsCount).' failed to import.';
}

return $body;
Expand Down
4 changes: 2 additions & 2 deletions app/Filament/Imports/AirportImporter.php
Original file line number Diff line number Diff line change
Expand Up @@ -79,10 +79,10 @@ public function resolveRecord(): ?Airport

public static function getCompletedNotificationBody(Import $import): string
{
$body = 'Your airport import has completed and ' . number_format($import->successful_rows) . ' ' . str('row')->plural($import->successful_rows) . ' imported.';
$body = 'Your airport import has completed and '.number_format($import->successful_rows).' '.str('row')->plural($import->successful_rows).' imported.';

if ($failedRowsCount = $import->getFailedRowsCount()) {
$body .= ' ' . number_format($failedRowsCount) . ' ' . str('row')->plural($failedRowsCount) . ' failed to import.';
$body .= ' '.number_format($failedRowsCount).' '.str('row')->plural($failedRowsCount).' failed to import.';
}

return $body;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@
use App\Filament\Imports\AircraftImporter;
use App\Filament\Resources\AircraftResource;
use Filament\Actions;
use Filament\Resources\Pages\ListRecords;
use Filament\Actions\ExportAction;
use Filament\Actions\ImportAction;
use Filament\Resources\Pages\ListRecords;

class ListAircraft extends ListRecords
{
Expand Down

0 comments on commit 44bee8c

Please sign in to comment.