From a4a8b9ded28c7281587d67436cf92911f2d33216 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Emilio=20Cobos=20=C3=81lvarez?= Date: Fri, 25 Oct 2019 13:02:22 +0000 Subject: [PATCH] Bug 1590816 - Make GetLinkDocument a static function again. r=mak Now without a duplicate version on another file :) Differential Revision: https://phabricator.services.mozilla.com/D50266 --HG-- extra : moz-landing-system : lando --- docshell/base/BaseHistory.cpp | 2 +- docshell/base/BaseHistory.h | 2 -- 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/docshell/base/BaseHistory.cpp b/docshell/base/BaseHistory.cpp index 0630d08e7d18..7fa0aba57c99 100644 --- a/docshell/base/BaseHistory.cpp +++ b/docshell/base/BaseHistory.cpp @@ -14,7 +14,7 @@ namespace mozilla { using mozilla::dom::Document; using mozilla::dom::Link; -Document* BaseHistory::GetLinkDocument(Link& aLink) { +static Document* GetLinkDocument(const Link& aLink) { Element* element = aLink.GetElement(); // Element can only be null for mock_Link. return element ? element->OwnerDoc() : nullptr; diff --git a/docshell/base/BaseHistory.h b/docshell/base/BaseHistory.h index b326713cace0..7312e6e4f702 100644 --- a/docshell/base/BaseHistory.h +++ b/docshell/base/BaseHistory.h @@ -31,8 +31,6 @@ class BaseHistory : public IHistory { // use the results anymore. virtual void CancelVisitedQueryIfPossible(nsIURI*) = 0; - static dom::Document* GetLinkDocument(dom::Link&); - using ObserverArray = nsTObserverArray; struct TrackedURI { ObserverArray mLinks;