Merge pull request #11069 from SomeoneElse2/master

Fix ATM transactions failing
This commit is contained in:
PsiOmegaDelta
2015-09-11 13:06:35 +02:00

View File

@@ -80,7 +80,7 @@
for(var/datum/money_account/D in all_money_accounts) for(var/datum/money_account/D in all_money_accounts)
if(D.account_number == attempt_account_number && !D.suspended) if(D.account_number == attempt_account_number && !D.suspended)
D.money += amount D.money += amount
//create a transaction log entry //create a transaction log entry
var/datum/transaction/T = new() var/datum/transaction/T = new()
T.target_name = source_name T.target_name = source_name
@@ -93,10 +93,9 @@
T.time = worldtime2text() T.time = worldtime2text()
T.source_terminal = terminal_id T.source_terminal = terminal_id
D.transaction_log.Add(T) D.transaction_log.Add(T)
return 1 return 1
break
return 0 return 0
//this returns the first account datum that matches the supplied accnum/pin combination, it returns null if the combination did not match any account //this returns the first account datum that matches the supplied accnum/pin combination, it returns null if the combination did not match any account