Specification document is not html

merge-requests/30/head
Bob Mottram 2022-06-28 10:07:22 +01:00
parent 0331311dd0
commit c5cec065b7
1 changed files with 7 additions and 9 deletions

View File

@ -4864,15 +4864,13 @@ class PubServer(BaseHTTPRequestHandler):
if fields.get('editedSpecification'): if fields.get('editedSpecification'):
specification_str = fields['editedSpecification'] specification_str = fields['editedSpecification']
if not dangerous_markup(specification_str, try:
allow_local_network_access): with open(specification_filename, 'w+',
try: encoding='utf-8') as specificationfile:
with open(specification_filename, 'w+', specificationfile.write(specification_str)
encoding='utf-8') as specificationfile: except OSError:
specificationfile.write(specification_str) print('EX: unable to write specification ' +
except OSError: specification_filename)
print('EX: unable to write specification ' +
specification_filename)
else: else:
if os.path.isfile(specification_filename): if os.path.isfile(specification_filename):
try: try: