]> source.dussan.org Git - nextcloud-server.git/commitdiff
fix: Replace conflicting tags in `xml_exception` template 47785/head
authorFerdinand Thiessen <opensource@fthiessen.de>
Fri, 6 Sep 2024 14:49:33 +0000 (16:49 +0200)
committerLouis <louis@chmn.me>
Mon, 9 Sep 2024 15:30:19 +0000 (17:30 +0200)
The `<?xml` tag is interpreted as PHP short tags, so this causes errors.
Instead just print that part of the template.

Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
core/templates/xml_exception.php

index d7fb276a7306bf30b1b34bd6d9992b256f2cdda4..342238d824bb7eb19e23f3f2a5f5b6a4977ab502 100644 (file)
@@ -15,8 +15,8 @@ function print_exception(Throwable $e, \OCP\IL10N $l): void {
        }
 }
 
+print_unescaped('<?xml version="1.0" encoding="utf-8"?>' . "\n");
 ?>
-<?xml version="1.0" encoding="utf-8"?>
 <d:error xmlns:d="DAV:" xmlns:s="http://sabredav.org/ns">
        <s:exception><?php p($l->t('Internal Server Error')) ?></s:exception>
        <s:message>