mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-12-12 01:42:32 +00:00
Auto commit for release 'develop' on 2025-02-08
This commit is contained in:
@@ -56,20 +56,23 @@ abstract class Node
|
||||
|
||||
}
|
||||
|
||||
public function equals(Node $compare): bool
|
||||
public function equals(self $compare): bool
|
||||
{
|
||||
if ($compare->isProhibited(false) !== $this->isProhibited(false)) {
|
||||
Log::debug('Return false because prohibited status is different');
|
||||
|
||||
return false;
|
||||
}
|
||||
if ($compare instanceof NodeGroup) {
|
||||
if (count($compare->getNodes()) !== count($this->getNodes())) {
|
||||
Log::debug(sprintf('Return false because node count is different. Original is %d, compare is %d', count($this->getNodes()), count($compare->getNodes())));
|
||||
// var_dump($this);
|
||||
// var_dump($compare);
|
||||
// exit;
|
||||
|
||||
// var_dump($this);
|
||||
// var_dump($compare);
|
||||
// exit;
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
* @var int $index
|
||||
* @var Node $node
|
||||
@@ -79,12 +82,16 @@ abstract class Node
|
||||
Log::debug('Return false because nodes are different!');
|
||||
var_dump($this);
|
||||
var_dump($compare);
|
||||
|
||||
exit;
|
||||
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -71,7 +71,7 @@ class QueryParser implements QueryParserInterface
|
||||
|
||||
while ($this->position < strlen($this->query)) {
|
||||
$char = $this->query[$this->position];
|
||||
//Log::debug(sprintf('Char #%d: %s', $this->position, $char));
|
||||
// Log::debug(sprintf('Char #%d: %s', $this->position, $char));
|
||||
|
||||
// If we're in a quoted string, we treat all characters except another quote as ordinary characters
|
||||
if ($inQuotes) {
|
||||
|
||||
@@ -125,7 +125,7 @@ class Steam
|
||||
foreach ($set as $entry) {
|
||||
// get date object
|
||||
$carbon = new Carbon($entry->date, $entry->date_tz);
|
||||
$carbonKey = $carbon->format('Y-m-d');
|
||||
$carbonKey = $carbon->format('Y-m-d');
|
||||
// make sure sum is a string:
|
||||
$sumOfDay = (string) (null === $entry->sum_of_day ? '0' : $entry->sum_of_day);
|
||||
|
||||
@@ -150,7 +150,7 @@ class Steam
|
||||
$currentBalance['native_balance'] = bcadd($currentBalance['native_balance'], $nativeSumOfDay);
|
||||
}
|
||||
// just set it.
|
||||
$balances[$carbonKey] = $currentBalance;
|
||||
$balances[$carbonKey] = $currentBalance;
|
||||
Log::debug(sprintf('Updated entry [%s]', $carbonKey), $currentBalance);
|
||||
}
|
||||
$cache->store($balances);
|
||||
@@ -274,8 +274,8 @@ class Steam
|
||||
$cache->addProperty($account->id);
|
||||
$cache->addProperty($date);
|
||||
if ($cache->has()) {
|
||||
// Log::debug(sprintf('CACHED finalAccountBalance(#%d, %s)', $account->id, $date->format('Y-m-d H:i:s')));
|
||||
// return $cache->get();
|
||||
// Log::debug(sprintf('CACHED finalAccountBalance(#%d, %s)', $account->id, $date->format('Y-m-d H:i:s')));
|
||||
// return $cache->get();
|
||||
}
|
||||
Log::debug(sprintf('finalAccountBalance(#%d, %s)', $account->id, $date->format('Y-m-d H:i:s')));
|
||||
|
||||
|
||||
@@ -116,7 +116,7 @@ class AmountFormat extends AbstractExtension
|
||||
|
||||
/** @var TransactionCurrency $currency */
|
||||
$currency = TransactionCurrency::whereCode($code)->first();
|
||||
if(null === $currency) {
|
||||
if (null === $currency) {
|
||||
Log::error(sprintf('Could not find currency with code "%s". Fallback to native currency.', $code));
|
||||
$currency = Amount::getNativeCurrency();
|
||||
Log::error(sprintf('Fallback currency is "%s".', $currency->code));
|
||||
|
||||
@@ -72,7 +72,7 @@ class General extends AbstractExtension
|
||||
$default = Amount::getNativeCurrency();
|
||||
$convertToNative = Amount::convertToNative();
|
||||
$useNative = $convertToNative && $default->id !== $currency->id;
|
||||
$currency = null === $currency ? $default : $currency;
|
||||
$currency = null === $currency ? $default : $currency;
|
||||
$strings = [];
|
||||
foreach ($info as $key => $balance) {
|
||||
if ('balance' === $key) {
|
||||
|
||||
Reference in New Issue
Block a user