From 785b277bb52e01cd5e45f4caadda6b7655c5b816 Mon Sep 17 00:00:00 2001 From: joshuaruesweg Date: Tue, 25 Jan 2022 10:33:41 +0100 Subject: [PATCH] Fix poll management within the form builder Fixes #4648 --- ts/WoltLabSuite/Core/Ui/Poll/Editor.ts | 2 +- wcfsetup/install/files/js/WoltLabSuite/Core/Ui/Poll/Editor.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/ts/WoltLabSuite/Core/Ui/Poll/Editor.ts b/ts/WoltLabSuite/Core/Ui/Poll/Editor.ts index 743ec5e7f7..4b064e8eee 100644 --- a/ts/WoltLabSuite/Core/Ui/Poll/Editor.ts +++ b/ts/WoltLabSuite/Core/Ui/Poll/Editor.ts @@ -313,7 +313,7 @@ class UiPollEditor { this.getOptions().forEach((option, i) => { const input = document.createElement("input"); input.type = "hidden"; - input.name = `${this.wysiwygId} + 'Poll_options[${i}}]`; + input.name = `${this.wysiwygId}Poll_options[${i}]`; input.value = option; form.appendChild(input); }); diff --git a/wcfsetup/install/files/js/WoltLabSuite/Core/Ui/Poll/Editor.js b/wcfsetup/install/files/js/WoltLabSuite/Core/Ui/Poll/Editor.js index 69025ebd9d..1a34f53eb8 100644 --- a/wcfsetup/install/files/js/WoltLabSuite/Core/Ui/Poll/Editor.js +++ b/wcfsetup/install/files/js/WoltLabSuite/Core/Ui/Poll/Editor.js @@ -222,7 +222,7 @@ define(["require", "exports", "tslib", "../../Core", "../../Language", "../Sorta this.getOptions().forEach((option, i) => { const input = document.createElement("input"); input.type = "hidden"; - input.name = `${this.wysiwygId} + 'Poll_options[${i}}]`; + input.name = `${this.wysiwygId}Poll_options[${i}]`; input.value = option; form.appendChild(input); }); -- 2.20.1