Skip to content

Instantly share code, notes, and snippets.

@eventualbuddha
Created July 17, 2010 23:49
Show Gist options
  • Save eventualbuddha/479950 to your computer and use it in GitHub Desktop.
Save eventualbuddha/479950 to your computer and use it in GitHub Desktop.
diff --git a/lib/importer/wesabe.rb b/lib/importer/wesabe.rb
index 2b1e348..fc4b69d 100644
--- a/lib/importer/wesabe.rb
+++ b/lib/importer/wesabe.rb
@@ -418,7 +418,8 @@ class Importer
when false, nil
# nothing to do
else
- if transfer = txactions[datum['transfer']['id']][0]
+ transfer, = txactions[datum['transfer']['id']]
+ if transfer
txaction.set_transfer_buddy!(transfer)
else
Rails.logger.warn "Unable to locate transfer for transaction (#{txaction.inspect}), marking it as unpaired"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment