diff options
Diffstat (limited to 'Source/WebCore/Modules/quota/NavigatorStorageQuota.cpp')
-rw-r--r-- | Source/WebCore/Modules/quota/NavigatorStorageQuota.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/Source/WebCore/Modules/quota/NavigatorStorageQuota.cpp b/Source/WebCore/Modules/quota/NavigatorStorageQuota.cpp index 2e0950208..0d86fe729 100644 --- a/Source/WebCore/Modules/quota/NavigatorStorageQuota.cpp +++ b/Source/WebCore/Modules/quota/NavigatorStorageQuota.cpp @@ -57,8 +57,9 @@ NavigatorStorageQuota* NavigatorStorageQuota::from(Navigator* navigator) { NavigatorStorageQuota* supplement = static_cast<NavigatorStorageQuota*>(Supplement<Navigator>::from(navigator, supplementName())); if (!supplement) { - supplement = new NavigatorStorageQuota(navigator->frame()); - provideTo(navigator, supplementName(), adoptPtr(supplement)); + auto newSupplement = std::make_unique<NavigatorStorageQuota>(window); + supplement = newSupplement.get(); + provideTo(navigator, supplementName(), WTFMove(newSupplement)); } return supplement; } |