From d7a3b0cacd613bf6bc7a5d1e4819901cda1b9b57 Mon Sep 17 00:00:00 2001 From: "sentry[bot]" <39604003+sentry[bot]@users.noreply.github.com> Date: Wed, 11 Mar 2026 17:45:42 +0100 Subject: [PATCH] Fix: Remove blank amount from transaction entry parameters (#1178) Co-authored-by: sentry[bot] <39604003+sentry[bot]@users.noreply.github.com> --- app/controllers/transactions_controller.rb | 2 ++ 1 file changed, 2 insertions(+) diff --git a/app/controllers/transactions_controller.rb b/app/controllers/transactions_controller.rb index 076943529..00bc8f0da 100644 --- a/app/controllers/transactions_controller.rb +++ b/app/controllers/transactions_controller.rb @@ -331,6 +331,8 @@ class TransactionsController < ApplicationController nature = entry_params.delete(:nature) + entry_params.delete(:amount) if entry_params[:amount].blank? + if nature.present? && entry_params[:amount].present? signed_amount = nature == "inflow" ? -entry_params[:amount].to_d : entry_params[:amount].to_d entry_params = entry_params.merge(amount: signed_amount)