summaryrefslogtreecommitdiffstats
path: root/dom/html
diff options
context:
space:
mode:
Diffstat (limited to 'dom/html')
-rw-r--r--dom/html/nsHTMLDocument.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/dom/html/nsHTMLDocument.cpp b/dom/html/nsHTMLDocument.cpp
index 69e710242..d64c27727 100644
--- a/dom/html/nsHTMLDocument.cpp
+++ b/dom/html/nsHTMLDocument.cpp
@@ -886,7 +886,7 @@ nsHTMLDocument::GetDomain(nsAString& aDomain)
nsCOMPtr<nsIURI> uri = GetDomainURI();
if (!uri) {
- SetDOMStringToNull(aDomain);
+ aDomain.Truncate();
return NS_OK;
}
@@ -896,8 +896,8 @@ nsHTMLDocument::GetDomain(nsAString& aDomain)
CopyUTF8toUTF16(hostName, aDomain);
} else {
// If we can't get the host from the URI (e.g. about:, javascript:,
- // etc), just return an null string.
- SetDOMStringToNull(aDomain);
+ // etc), just return an empty string.
+ aDomain.Truncate();
}
return NS_OK;
}