fix(transactions): Ignore blank date in entry params (#1688)

Co-authored-by: sentry[bot] <39604003+sentry[bot]@users.noreply.github.com>
This commit is contained in:
sentry[bot]
2026-05-06 20:27:18 +02:00
committed by GitHub
parent ec4559ba26
commit 4b93bdb447

View File

@@ -446,6 +446,7 @@ class TransactionsController < ApplicationController
nature = entry_params.delete(:nature)
entry_params.delete(:amount) if entry_params[:amount].blank?
entry_params.delete(:date) if entry_params[:date].blank?
if nature.present? && entry_params[:amount].present?
signed_amount = nature == "inflow" ? -entry_params[:amount].to_d : entry_params[:amount].to_d