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

middleware : catch promise error. #45

Open
guillaumearm opened this issue Oct 11, 2016 · 3 comments
Open

middleware : catch promise error. #45

guillaumearm opened this issue Oct 11, 2016 · 3 comments
Milestone

Comments

@guillaumearm
Copy link
Collaborator

guillaumearm commented Oct 11, 2016

performGetPhrases()(see middleware.js in V2 branch) doesn't catch promise error.

@guillaumearm
Copy link
Collaborator Author

guillaumearm commented Oct 20, 2016

@JalilArfaoui ? what are we doing when getLocale() or getPhrases() reject a value ?

maybe same as #17 ?

@JalilArfaoui
Copy link
Contributor

IMHO, getLocale() returning a falsy value should have the same effect as a non-corresponding action : nothing happens, we simply return next(action).
As for getPhrases(), it should always return something. If empty object, we dispatch SET_LANGAGE with empty phrases. If falsy response anyway, we warn about it and return next(action).
What do you think ?

@guillaumearm
Copy link
Collaborator Author

yes, ok for this in #17, but what about rejecting value (promise) ? (see PR #43)

@guillaumearm guillaumearm added this to the v0.4 milestone Dec 6, 2016
@guillaumearm guillaumearm modified the milestones: v1.0, v0.4 Jan 13, 2017
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

2 participants