Clean up method relying on old transaction journal code.

This commit is contained in:
James Cole
2016-03-02 20:11:28 +01:00
parent 5b949d6e00
commit 7234f011ec
19 changed files with 156 additions and 48 deletions

View File

@@ -54,7 +54,7 @@ final class AmountLess extends AbstractTrigger implements TriggerInterface
*/
public function triggered(TransactionJournal $journal)
{
$amount = $journal->amount_positive; // TODO TransactionJournal cannot deliver "amount_positive".
$amount = TransactionJournal::amountPositive($journal);
$compare = $this->triggerValue;
$result = bccomp($amount, $compare, 4);
if ($result === -1) {