Skip to content

Commit

Permalink
Test clearing catalogue with #clean
Browse files Browse the repository at this point in the history
  • Loading branch information
steve9164 committed Feb 22, 2023
1 parent 3e9ea2d commit 75fc26b
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions lib/Models/Terria.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2063,6 +2063,10 @@ async function interpretHash(
if (isDefined(hashProperties.clean)) {
runInAction(() => {
terria.initSources.splice(0, terria.initSources.length);
// Clear out catalogue
for (let key of terria.catalog.group.strata.keys()) {
terria.catalog.group.setTrait(key, "members", []);
}
});
}

Expand Down

0 comments on commit 75fc26b

Please sign in to comment.