Fix user.canSubscribe method code 1000, "An unexpected error occurred… #298
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
…" error
Several users (including myself) experience an issue where Pandora API
user.canSubscribe
method throws error with code1000
and message"An unexpected error occurred"
.user.canSubscribe
method is called incheckSubscriberStatus
function, the sole purpose of which is to determine whether the user is a subscriber.It is possible to get the same information just by passing additional parameter
returnIsSubscriber: true
inauth.userLogin
, which is called beforecheckSubscriberStatus
anyway.I have removed
checkSubscriberStatus
function (which was called in 1 place only) and replaced the functionality of getting subscriber status by passing additional parameterreturnIsSubscriber: true
inauth.userLogin
.Tested with both free and paid accounts.
Please let me know if you need me to do anything else.
This is my first pull request, so I am sorry if I missed anything.