summaryrefslogtreecommitdiff
path: root/bs4/element.py
diff options
context:
space:
mode:
authorLeonard Richardson <leonard.richardson@canonical.com>2012-02-26 09:22:42 -0500
committerLeonard Richardson <leonard.richardson@canonical.com>2012-02-26 09:22:42 -0500
commitf224b8536ce266538bcfa492ec8d2b3b41fceae5 (patch)
tree30d431989c7a5b18da139c8a03d433d5ce2b119d /bs4/element.py
parent105aa2f9a9f833ff98c1706290b07e9228e008a6 (diff)
Fixed DOCTYPE handling.
Diffstat (limited to 'bs4/element.py')
-rw-r--r--bs4/element.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/bs4/element.py b/bs4/element.py
index cdc9e36..e50f639 100644
--- a/bs4/element.py
+++ b/bs4/element.py
@@ -507,7 +507,9 @@ class Doctype(NavigableString):
value = name
if pub_id is not None:
value += ' PUBLIC "%s"' % pub_id
- if system_id is not None:
+ if system_id is not None:
+ value += ' "%s"' % system_id
+ elif system_id is not None:
value += ' SYSTEM "%s"' % system_id
return Doctype(value)