fix(studyPrefetcher): Avoid errors in Study Prefetcher when settings are undefined
This commit is contained in:
parent
69ea0f488c
commit
b8eadd6d61
@ -131,7 +131,18 @@ export class StudyPrefetcher {
|
|||||||
}
|
}
|
||||||
|
|
||||||
prefetchDisplaySets() {
|
prefetchDisplaySets() {
|
||||||
const config = Meteor.settings.public.prefetch;
|
let config;
|
||||||
|
if (Meteor.settings &&
|
||||||
|
Meteor.settings.public &&
|
||||||
|
Meteor.settings.prefetch) {
|
||||||
|
config = Meteor.settings.public.prefetch;
|
||||||
|
} else {
|
||||||
|
config = {
|
||||||
|
order: 'closest',
|
||||||
|
displaySetCount: 1
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
const displaySetsToPrefetch = this.getDisplaySetsToPrefetch(config);
|
const displaySetsToPrefetch = this.getDisplaySetsToPrefetch(config);
|
||||||
const imageIds = this.getImageIdsFromDisplaySets(displaySetsToPrefetch);
|
const imageIds = this.getImageIdsFromDisplaySets(displaySetsToPrefetch);
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user