-
Notifications
You must be signed in to change notification settings - Fork 367
Backport globalization #1029
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
Backport globalization #1029
Conversation
|
For now I have not squashed into one commit; I can do it if you think it is necessary after review. |
lib/dao.js
Outdated
| } | ||
| } else { | ||
| err = new Error(util.format('The order %j is not valid', order[i])); | ||
| err = new Error('The order %j is not valid', order[i]); |
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.
g.f()
lib/include.js
Outdated
| if (!relation.polymorphic) { | ||
| cb(new Error('Relation.modelTo is not defined for relation' + | ||
| relationName + ' and is no polymorphic')); | ||
| cb(new Error(g.f('{{Relation.modelTo}} is not defined for relation %s and is no polymorphic', |
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.
{{Polymorphic}}
|
LGTM, only two comments 👍 |
package.json
Outdated
| "loopback-connector": "^2.1.0", | ||
| "node-uuid": "^1.4.2", | ||
| "qs": "^3.1.0", | ||
| "strong-globalize": "^2.6.0", |
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.
^2.6.2
|
@Amir-61 Two comments, otherwise LGTM. |
|
@Amir-61 Please squash before merging too. |
lib/datasource.js
Outdated
| // The connection fails, let's report it and hope it will be recovered in the next call | ||
| console.error('Connection fails: ', err, '\nIt will be retried for ' + | ||
| 'the next request.'); | ||
| console.error(g.f('Connection fails: %s\nIt will be retried for the next request.', err)); |
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.
just use g.error instead of console.error(g.f
225676f to
642838b
Compare
|
Thanks for reviewing! 🙇 I applied your feedback and I'm going to land it after checking CI. Thanks! |
642838b to
6debb50
Compare
Backport loopback-datasource-juggler#1022, loopback-datasource-juggler#1024, loopback-datasource-juggler#1026
bdae2a8 to
9da0e50
Compare
Backporting these 3 PRs of globalization:
#1022
#1024
#1026
This backporting needs very careful review since there were tons of merge conflicts and there is a possibility of doing something wrong!
I would like to get LGTM from @superkhau @0candy @jannyHou individually to make sure everything looks good and merge conflicts have been solved safely.
Thanks a lot!