-
Notifications
You must be signed in to change notification settings - Fork 60
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
Show Central version in modal #1099
base: master
Are you sure you want to change the base?
Conversation
src/request-data/resources.js
Outdated
const result = typeof data === 'object' && data != null | ||
? mergeDeepLeft(data, configDefaults) | ||
: configDefaults; | ||
result.currentDate = new Date(headers.get('date')); |
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.
I wanted to keep currentDate
somewhat current. May be later on we can update this variable (or move to a provide/inject) whenever there is any API response from the backend.
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.
I like that idea! I think I could fit that in this PR pretty easily.
Closes getodk/central#849.
What has been done to verify that this works as intended?
I've tried it out locally. However, this is a draft PR, and I haven't added tests yet.
Why is this the best possible solution? Were any other approaches considered?
Once we're ready for code review, I'll add comments about individual lines.
Before submitting this PR, please make sure you have:
npm run test
andnpm run lint
and confirmed all checks still pass OR confirm CircleCI build passes