-
Notifications
You must be signed in to change notification settings - Fork 1
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
Made RTD endpoint optional. Read the floors from local storage if the dynamic endpoint is not provided. #23
Conversation
…e dynamic endpoint is not provided.
Tread carefully! This PR adds 2 linter errors (possibly disabled through directives):
|
Tread carefully! This PR adds 2 linter errors (possibly disabled through directives):
|
modules/pubxaiRtdProvider.js
Outdated
} else { | ||
// Fetch from local storage | ||
try { | ||
const localData = storage.getDataFromLocalStorage('pubx:dynamicFloors') || window.__pubxDynamicFloors__; |
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.
This data is written to localStorage by RTD module or will be written by the external floors loading script?
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.
yes
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.
lgtm
Type of change
Description of change
Providing RTD endpoint param is optional now. In case of missing RTD endpoint, it tries to read the required data either from local storage or from global variables.