Bug 1919721 - Check size before building an empty placements list from gFuturePlacements in CustomizableUI. r=mconley
Differential Revision: https://phabricator.services.mozilla.com/D224268
This commit is contained in:
@@ -2934,7 +2934,7 @@ var CustomizableUIInternal = {
|
||||
getAreaPlacementsForSaving(area) {
|
||||
// An early call to saveState can occur before all the lazy-area building is complete
|
||||
let placements;
|
||||
if (this.isAreaLazy(area) && gFuturePlacements.has(area)) {
|
||||
if (this.isAreaLazy(area) && gFuturePlacements.get(area)?.size) {
|
||||
placements = [...gFuturePlacements.get(area)];
|
||||
} else if (gPlacements.has(area)) {
|
||||
placements = gPlacements.get(area);
|
||||
|
||||
Reference in New Issue
Block a user