1
0
mirror of https://git.savannah.gnu.org/git/emacs.git synced 2025-02-03 20:24:29 +00:00

`url-domain' doc clarification

* lisp/url/url-util.el (url-domain): Add an example to the doc
string.
This commit is contained in:
Lars Ingebrigtsen 2018-05-01 14:29:11 +02:00
parent e859acb11c
commit b3b4697ff8

View File

@ -632,8 +632,11 @@ Creates FILE and its parent directories if they do not exist."
;;;###autoload
(defun url-domain (url)
"Return the domain of the host of the url.
Return nil if this can't be determined."
"Return the domain of the host of the URL.
Return nil if this can't be determined.
For instance, this function will return \"fsf.co.uk\" if the host in URL
is \"www.fsf.co.uk\"."
(let* ((host (puny-encode-domain (url-host url)))
(parts (nreverse (split-string host "\\.")))
(candidate (pop parts))