From ce2a175e88fca28af6940fdcfd24cf2f91e4211e Mon Sep 17 00:00:00 2001 From: Jacob Atzen Date: Sat, 19 Oct 2024 11:58:34 +0200 Subject: [PATCH] Default value for Account needs to be a callable Schema only supports callable values since 2225df65810f7c2f12dded789b28fbc79b0a10a2. --- lib/account_component/account.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/account_component/account.rb b/lib/account_component/account.rb index 6ee642f..3b55a94 100644 --- a/lib/account_component/account.rb +++ b/lib/account_component/account.rb @@ -4,7 +4,7 @@ class Account attribute :id, String attribute :customer_id, String - attribute :balance, Numeric, default: 0 + attribute :balance, Numeric, default: -> { 0 } attribute :opened_time, Time attribute :closed_time, Time attribute :sequence, Integer