lib/ledgerizer/locking.rb
def create_missing_account_balances
        @accounts_without_balances.each do |account|
          # Try to create the balance record,
          # but ignore it if someone else has done it in the meantime.
          Ledgerizer::Account.create_ignoring_duplicates!(
            account.to_hash.merge(balance: account.balance)
          )
        end
      end
# Create the account_balances for the given accounts.
Create the account_balances for the given accounts.
Create the account_balances for the given accounts .
def create_missing_account_balances
        @accounts_without_balances.each do |account|
          Ledgerizer::Account.create_ignoring_duplicates!(
            account.to_hash.merge(balance: account.balance)
          )
        end
      end
def create_missing_account_balances @accounts_without_balances . each do | account | Ledgerizer :: Account . create_ignoring_duplicates! ( account . to_hash . merge ( balance : account . balance ) ) end end
Create the account_balances for the given accounts.
Create the account_balances for the given accounts .
# Try to create the balance record, # but ignore it if someone else has done it in the meantime.