🏠 Home 

讨论 » Greasy Fork 反馈

Adding localized additional info is broken

§
发表于:2025-02-09

When I go to the Admin tab of my script and click the "Add a localized, synced additional info" button, the elements are always added with index 0: "additional_info_sync[0][sync_identifier]", "additional_info_sync[0][value_markup]" etc. This breaks radio buttons and makes adding additional infos impossible.

The same thing happens when pressing "Add a localized additional info" on the Update tab.

JasonBarnabe管理员
§
发表于:2025-02-12

I can't reproduce the bug; both places work for me. What browser are you using?

§
发表于:2025-02-12

The issue is caused by switching locales. The generated URL becomes "https://greasyfork.org/en/scripts/sync_additional_info_form?locale_override=1?index=1".

- xhr.open("get", button.getAttribute("data-form-path") + "?index=" + index);
+ const appendSearchChar = button.dataset.formPath.includes("?") ? "&" : "?";
+ xhr.open("get", `${button.dataset.formPath}${appendSearchChar}index=${index}`);
JasonBarnabe管理员
§
发表于:2025-02-12

Fixed now.

发表回复

登录以发表回复。