Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Exposed accessToken to JS #26

Open
wants to merge 4 commits into
base: master
Choose a base branch
from
Open

Exposed accessToken to JS #26

wants to merge 4 commits into from

Conversation

aahan96
Copy link

@aahan96 aahan96 commented Jan 30, 2018

Exposes the accessToken to the React Native code for simultaneous use of Spotify Web Api.

Fixes #19

Copy link
Author

@aahan96 aahan96 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed a few things

if(!error){
SpotifyModule.startAuthenticationFlow((error, str) => {
if(!error){
console.log("New Access Token = "+str);
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would change this to template literals:
`New Access Token ${str}`

@@ -47,6 +48,7 @@ class logIn extends Component {
}
});
} else {
console.log("Cached Access Token = "+accessToken);
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

here too :)

block(@[notification.userInfo[@"error"]]);
} else {
block(@[[NSNull null]]);
block(@[notification.userInfo[@"error"], @"not wow"]);
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe a more descriptive message.

Copy link
Owner

@viestat viestat left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please note my comments about super small changes, but it looks good to me in general.
Would be also nice if README was also updated in the same PR but I can do that later.

Thanks :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants