From 1913b66b2c8db94e8b84848b2733c97595ee25e8 Mon Sep 17 00:00:00 2001 From: ralf Date: Tue, 16 Apr 2024 09:17:53 +0200 Subject: [PATCH] replace no longer used and existing with --- api/etemplate.php | 12 +++++++----- mail/templates/default/folder_management.xet | 4 +++- mail/templates/default/subscribe.xet | 5 ++++- 3 files changed, 14 insertions(+), 7 deletions(-) diff --git a/api/etemplate.php b/api/etemplate.php index 14a3f31310..31ac42ff3b 100644 --- a/api/etemplate.php +++ b/api/etemplate.php @@ -420,22 +420,24 @@ function send_template() return ""; }, $str); - // replace #s', static function (array $matches) { $tag = 'et2-tree'.($matches[1] ?? ''); $attrs = parseAttrs($matches[2]); - if (!empty($attrs['multiple']) && $attrs['multiple'] !== 'false' || - !empty($attrs['options']) && (int)$attrs['options'] > 1) + if (!empty($attrs['options']) && (int)$attrs['options'] > 1) { - $tag .= '-multiple'; + $attrs['multiple'] = 'true'; } // fix renamed attrs, thought regular under_score to camelCase happens later if (!empty($attrs['parent_node'])) $attrs['parentId'] = $attrs['parent_node']; - unset($attrs['multiple'], $attrs['options'], $attrs['parent_node']); + unset($attrs['options'], $attrs['parent_node']); return "<$tag" . stringAttrs($attrs) . ">"; }, $str); + // replace no longer used with + $str = preg_replace('#]+)(/>|)#', '', $str); + if ($template === 'mobile') { } diff --git a/mail/templates/default/folder_management.xet b/mail/templates/default/folder_management.xet index bc465a0e79..f2a308674d 100644 --- a/mail/templates/default/folder_management.xet +++ b/mail/templates/default/folder_management.xet @@ -6,7 +6,9 @@ - + diff --git a/mail/templates/default/subscribe.xet b/mail/templates/default/subscribe.xet index e9b43760a4..943e7ee9ff 100755 --- a/mail/templates/default/subscribe.xet +++ b/mail/templates/default/subscribe.xet @@ -6,7 +6,10 @@ - +