Fix refactor for field.

This commit is contained in:
James Cole 2023-10-22 08:05:28 +02:00
parent 80237d8bc3
commit c3398d4d51
No known key found for this signature in database
GPG Key ID: B49A324B7EAD6D80

View File

@ -108,8 +108,9 @@ class Amount
*/
public function getCurrencies(): Collection
{
throw new FireflyException(sprintf('Method "%s" needs a refactor', __METHOD__));
return TransactionCurrency::where('enabled', true)->orderBy('code', 'ASC')->get();
/** @var User $user */
$user = auth()->user();
return $user->currencies()->orderBy('code','ASC')->get();
}
/**