redux-polyglot
redux-polyglot copied to clipboard
getLocale()/getPhrases() can return a falsy value.
for v1.0
need #16
this will stop the progression :
- if
getLocale()orgetPhrases()return or resolve a falsy value, shouldreturn next(action) - add 'previousLocale' as second parameter of getLocale() to determine if the locale have been changed.
about this behavior :
- need tests
- need doc
I think it should return next(action), not return action
yes, you're right. i don't remember why I thought to do that when I wrote this issue :)
I remember ! (for return action)
it's about SET_LANGUAGE action. we shouldn't propagate this action ( and only this action ) when return a falsy value.
but that's no longer news since #38. so don't worry about this ;-)