luci-app-frps: avoid saving the same form twice - #9012
Conversation
The status section renders a nested cbi-map without a bound form instance. LuCI resolves it to the enclosing map, so save and reset invoke that map twice. Concurrent saves can submit duplicate UCI delete requests and report resource not found. Remove the form marker from the status wrapper while retaining its fieldset and polling. This addresses the duplicate-save cause of issue openwrt#7679. Signed-off-by: Javen Li <j.wroiate@gmail.com>
3c92e31 to
4ca8719
Compare
| }); | ||
|
|
||
| return E('div', { class: 'cbi-map' }, | ||
| return E('div', {}, |
There was a problem hiding this comment.
nit: the sibling client app has the identical nested-cbi-map status wrapper at frpc.js:1415 and is left unchanged here, so frpc still double-saves. Is leaving it out intentional, or should the same one-line change land there too?
Generated by Claude Code
There was a problem hiding this comment.
I think the solution should be the same.
|
The current LuCI The code in the 现在这个LuCI的master分支,是我用AI设计的全新版本,你那个问题是老LuCI的25.12分支的问题,新版本没有这个问题。 这行master分支的代码应该是为了解决其他问题故意这样的,如果是25.12分支的问题,不应该提交到master分支。 |
The status section renders a nested cbi-map without a bound form instance. LuCI resolves it to the enclosing map, so save and reset invoke that map twice. Concurrent saves can submit duplicate UCI delete requests and report resource not found.
Pull request details
Description
Remove the form marker from the status wrapper while retaining its fieldset and polling. This addresses the duplicate-save cause of issue #7679.
Screenshot or video of changes (if applicable)
Related with issue #7679.
Maintainer (preferred)
Cannot find it in the Makefile, maybe ask @ysc3839 for help?
Tested on
OpenWrt version: ImmortalWrt 25.12.1 (OpenWrt downstream)
LuCI version: ImmortalWrt branch openwrt-25.12 26.187.07797~ed7692c (OpenWrt downstream)
Web browser(s): Edge 152.0.4191.53
Checklist