Skip to content

login() doesn't support redux-saga call effect #10

@peteroid

Description

@peteroid

Hi maintainer, thanks for the great effort on making this nice library.

I found that the method call of login doesn't work in the following scenario.

// this doesn't work
// the error message is about this.getUserInfo being undefined
const tryLogin = function * () {
  const user = yield call(SnapchatKit.Login)
}

// this works
const tryLogin = function * () {
  const user = yield SnapchatKit.Login()
}

I believe this behavior has been discussed in redux-saga/redux-saga#27.

I suggest we can make a use of the arrow function to define the class method as suggested in the issue.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions