-
Notifications
You must be signed in to change notification settings - Fork 46
fix(i18nCookie): handle case when cookie do not exist on client #566
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
Conversation
@@ -16,7 +16,7 @@ function encode(val) { | |||
} | |||
|
|||
function decode(val) { | |||
const vals = val.split(':'); | |||
const vals = val ? val.split(':') : []; | |||
if (vals.length < 2) { | |||
return {}; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
are you sure that now, when we return empty object, it will not thrown further by stack?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Indeed, this might bring some issues. I'll do an update.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Updated client i18n code to use defaults. Server already uses defaults.
Coverage ReportIlc/serverCommit SHA:b3baf7adeddad314ad4b5685aef5aefe59a7b587 Test coverage results 🧪
File details
Ilc/clientCommit SHA:b3baf7adeddad314ad4b5685aef5aefe59a7b587 Test coverage results 🧪
File details
RegistryCommit SHA:b3baf7adeddad314ad4b5685aef5aefe59a7b587 Test coverage results 🧪
File details
|
No description provided.