Issue #2339935 by Carlitus, aviindub: Added a lock around the card on file submit hook to prevent duplicate transactions from piling up. also improved handling of duplicates in the non-card-on-file case.
removes commented code.