Compare commits

...

6 Commits

Author SHA1 Message Date
github-actions[bot]
8852bb022b Merge pull request #11797 from firefly-iii/release-1771873461
🤖 Automatically merge the PR into the develop branch.
2026-02-23 20:04:29 +01:00
JC5
03d0d503b0 🤖 Auto commit for release 'develop' on 2026-02-23 2026-02-23 20:04:21 +01:00
James Cole
6b8c8c1b28 Merge pull request #11796 from R1DEN/main
fix operator order for pc_amount bug
2026-02-23 11:41:16 +01:00
R1DEN
e43a188af8 fix operator order for pc_amount bug 2026-02-23 11:54:48 +02:00
Sander Dorigo
a806bf3b10 Merge branch 'develop' of https://github.com/firefly-iii/firefly-iii into develop 2026-02-23 08:19:34 +01:00
Sander Dorigo
9b05c777cd Fix https://github.com/firefly-iii/firefly-iii/issues/11792 2026-02-23 08:08:46 +01:00
6 changed files with 15 additions and 8 deletions

View File

@@ -4,6 +4,7 @@ Over time, many people have contributed to Firefly III. Their efforts are not al
Please find below all the people who contributed to the Firefly III code. Their names are mentioned in the year of their first contribution.
## 2026
- R1DEN
- RiDEN
- Khoa Nguyen
- Nick Huang

View File

@@ -230,7 +230,11 @@ class AttachmentHelper implements AttachmentHelperInterface
$count = 0;
// ignore lines about polymorphic calls.
if ($model instanceof PiggyBank) {
$count = $model->account->user->attachments()->where('md5', $md5)->where('attachable_id', $model->id)->where('attachable_type', $class)->count();
$count = $model
->accounts()
->first()
->user->attachments()->where('md5', $md5)->where('attachable_id', $model->id)->where('attachable_type', $class)->count()
;
}
if (!$model instanceof PiggyBank) {
$count = $model->user->attachments()->where('md5', $md5)->where('attachable_id', $model->id)->where('attachable_type', $class)->count();
@@ -260,7 +264,7 @@ class AttachmentHelper implements AttachmentHelperInterface
$user = $model->user;
// ignore lines about polymorphic calls.
if ($model instanceof PiggyBank) {
$user = $model->account->user;
$user = $model->accounts()->first()->user;
}
$attachment = new Attachment(); // create Attachment object.

View File

@@ -188,6 +188,8 @@ class ExportDataGenerator
// @phpstan-ignore-line
// @phpstan-ignore-line
public function __construct()
{
$this->accounts = new Collection();

View File

@@ -388,7 +388,7 @@ class TransactionGroupTransformer extends AbstractTransformer
}
// set primary amount to the normal amount if the currency matches.
if ($transaction['primary_currency']['id'] ?? null === $transaction['currency_id']) {
if (($transaction['primary_currency']['id'] ?? null) === (string) $transaction['currency_id']) {
$transaction['pc_amount'] = $amount;
}

8
composer.lock generated
View File

@@ -11356,11 +11356,11 @@
},
{
"name": "phpstan/phpstan",
"version": "2.1.39",
"version": "2.1.40",
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/phpstan/phpstan/zipball/c6f73a2af4cbcd99c931d0fb8f08548cc0fa8224",
"reference": "c6f73a2af4cbcd99c931d0fb8f08548cc0fa8224",
"url": "https://api.github.com/repos/phpstan/phpstan/zipball/9b2c7aeb83a75d8680ea5e7c9b7fca88052b766b",
"reference": "9b2c7aeb83a75d8680ea5e7c9b7fca88052b766b",
"shasum": ""
},
"require": {
@@ -11405,7 +11405,7 @@
"type": "github"
}
],
"time": "2026-02-11T14:48:56+00:00"
"time": "2026-02-23T15:04:35+00:00"
},
{
"name": "phpstan/phpstan-deprecation-rules",

View File

@@ -79,7 +79,7 @@ return [
// see cer.php for exchange rates feature flag.
],
'version' => 'develop/2026-02-23',
'build_time' => 1771830094,
'build_time' => 1771873326,
'api_version' => '2.1.0', // field is no longer used.
'db_version' => 28, // field is no longer used.