christopherperry / RoboBillingLibrary

Google Play and Amazon Appstore In-app Billing Library
64 stars 11 forks source link

billingMode isn't set in DungeonRedux's Application.java file #5

Closed turbochan closed 11 years ago

turbochan commented 11 years ago

In the Application class of DungeonRedux there is a member field private BillingMode billingMode that never gets set.

It is however used to determine which salt to return in getObfuscationSalt().

public byte[] getObfuscationSalt() {
    return billingMode == BillingMode.GOOGLE ? salt : getUser().getUserId().
}

And since it's never actually set I'm assuming it will just constantly return the salt that was meant for Amazon (the Amazon userId) and will never return the Google version. Am I correct or am I missing something?

Shouldn't billingMode be a member field of the parent class (RoboBillingApplication) where it can be set since a local version is already being set in its onCreate()?

christopherperry commented 11 years ago

You're correct. This is an oversight on my part. You're more than welcome to submit a pull request.