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

Use default app access token in API #622

Open
ArmandoAssuncao opened this issue Aug 20, 2017 · 0 comments
Open

Use default app access token in API #622

ArmandoAssuncao opened this issue Aug 20, 2017 · 0 comments

Comments

@ArmandoAssuncao
Copy link

Hi,

I was trying to use the default app_access_token in the Koala::Facebook::API and saw that it is not possible.

Then I looked at the code:

args["access_token"] ||= @access_token || @app_access_token if @access_token || @app_access_token

I saw that args["access_token"] is only assigned by the @access_token. The @app_access_token will never be assigned because it does not start.

So I think it should look like this:

args["access_token"] ||= Koala.config.access_token || Koala.config.app_access_token if @access_token || Koala.config.app_access_token

Thus, if @access_token is not defined at initialize(), it will use Koala.config.access_token or Koala.config.app_access_token.

What do you think?

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

No branches or pull requests

1 participant