PHPStorm can order methods by alphabet, who knew.

This commit is contained in:
James Cole
2024-02-22 20:11:09 +01:00
parent f9d4a43e05
commit 68c9c4ec3c
221 changed files with 5840 additions and 5843 deletions

View File

@@ -70,7 +70,7 @@ class AppendNotesToDescription implements ActionInterface
// only append if there is something to append
if ('' !== $note->text) {
$before = $object->description;
$object->description = trim(sprintf('%s %s', $object->description, (string) $this->clearString($note->text)));
$object->description = trim(sprintf('%s %s', $object->description, (string)$this->clearString($note->text)));
$object->save();
app('log')->debug(sprintf('Journal description is updated to "%s".', $object->description));

View File

@@ -166,7 +166,7 @@ class ConvertToTransfer implements ActionInterface
return '';
}
return (string) $journal->transactions()->where('amount', '<', 0)->first()?->account?->accountType?->type;
return (string)$journal->transactions()->where('amount', '<', 0)->first()?->account?->accountType?->type;
}
private function getDestinationType(int $journalId): string
@@ -179,7 +179,7 @@ class ConvertToTransfer implements ActionInterface
return '';
}
return (string) $journal->transactions()->where('amount', '>', 0)->first()?->account?->accountType?->type;
return (string)$journal->transactions()->where('amount', '>', 0)->first()?->account?->accountType?->type;
}
/**

View File

@@ -77,7 +77,7 @@ class MoveNotesToDescription implements ActionInterface
}
$before = $object->description;
$beforeNote = $note->text;
$object->description = (string) $this->clearString($note->text);
$object->description = (string)$this->clearString($note->text);
$object->save();
$note->delete();