Double used bits payment transaction-ids

This is an issue with how the onTransactionComplete() function is used.

When a user completes a transaction, Twitch calls the callback you provide to that helper function on all browser tabs open by that specific user on the specific channel where the transaction happened. This will mean that if you have multiple tabs open on the same channel and one makes an in-extension bits transaction they will all receive that transaction receipt.

This does cause some potential problems, as tabs may not be able to differentiate if the onTransactionComplete() was called because of a purchase in that tab, or some other tab. The best thing you could do is to send all transactions to your EBS and let your EBS drop duplicates. This still leaves some window for error if you use the same product SKU for multiple in-extension products.

In RFC 0011 Twitch propose some changes, and some very useful additions, to this process so hopefully once that is fully implemented this will no longer be an issue.