summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--dom/html/HTMLMenuItemElement.cpp5
1 files changed, 2 insertions, 3 deletions
diff --git a/dom/html/HTMLMenuItemElement.cpp b/dom/html/HTMLMenuItemElement.cpp
index 6cf4eb40c..42cee132e 100644
--- a/dom/html/HTMLMenuItemElement.cpp
+++ b/dom/html/HTMLMenuItemElement.cpp
@@ -16,11 +16,10 @@
nsGenericHTMLElement*
NS_NewHTMLMenuItemElement(already_AddRefed<mozilla::dom::NodeInfo>&& aNodeInfo,
mozilla::dom::FromParser aFromParser) {
- RefPtr<mozilla::dom::NodeInfo> nodeInfo(aNodeInfo);
if (mozilla::Preferences::GetBool("dom.menuitem.enabled")) {
- return new mozilla::dom::HTMLMenuItemElement(nodeInfo.forget(), aFromParser);
+ return new mozilla::dom::HTMLMenuItemElement(aNodeInfo, aFromParser);
} else {
- return new mozilla::dom::HTMLUnknownElement(nodeInfo.forget());
+ return new mozilla::dom::HTMLUnknownElement(aNodeInfo);
}
}