Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
emacs
emacs
Commits
01af3a58
Commit
01af3a58
authored
Nov 03, 2014
by
Lars Magne Ingebrigtsen
Browse files
* net/shr.el (shr-retransform-dom): Allow several text sub-nodes.
parent
ab657bab
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
4 deletions
+2
-4
lisp/net/shr.el
lisp/net/shr.el
+2
-4
No files found.
lisp/net/shr.el
View file @
01af3a58
...
...
@@ -374,12 +374,11 @@ size, and full-buffer size."
"Transform the shr DOM back into the libxml DOM."
(let ((tag (car dom))
(attributes nil)
(text nil)
(sub-nodes nil))
(dolist (elem (cdr dom))
(cond
((eq (car elem) 'text)
(
setq text
(cdr elem)))
(
push
(cdr elem)
sub-nodes
))
((not (consp (cdr elem)))
(push (cons (intern (substring (symbol-name (car elem)) 1) obarray)
(cdr elem))
...
...
@@ -387,8 +386,7 @@ size, and full-buffer size."
(t
(push (shr-retransform-dom elem) sub-nodes))))
(append (list tag (nreverse attributes))
(nreverse sub-nodes)
(and text (list text)))))
(nreverse sub-nodes))))
(defsubst shr-generic (cont)
(dolist (sub cont)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment