btlqql commented on PR #4001:
URL: 
https://github.com/apache/rocketmq-dashboard/pull/4001#issuecomment-5651572286

   @lizhimins You are right, and I am closing this rather than asking you to 
re-review it.
   
   I went back to the code and confirmed your reasoning rather than just 
accepting it. `onOk={handleExtendTTL}` 
(`web/src/pages/studio/LiteTopic.tsx:885`) is the only call site, and the 
`<Form>` in the modal body (`:892`) has no `onFinish` — the modal footer sits 
outside that form, so the Enter and auto-repeat paths you floated do not reach 
the handler either. `handleOpenExtendTTL` at `:442` is the only way in. With 
`confirmLoading={extendTTLLoading}` and 
`node_modules/antd/es/button/button.js:184-187` returning before `onClick`, the 
guarded path really is unreachable. My test only produced two calls because 
both clicks were dispatched inside a single `act()`, so it was pinning a 
property of the harness, exactly as you said.
   
   I also agree about the duplication. Adding a thirteenth local in-flight 
guard while you are converging these onto one shared hook makes that work 
harder and buys nothing reachable, so it is not worth taking on those grounds 
either.
   
   Rather than leave it open as a repro-in-waiting: if I turn up a 
duplicate-submit path a user can genuinely reach, I will bring it back on top 
of the shared hook instead of as another local ref.
   
   Thank you for the specific write-up — pointing at the antd button source and 
at `pages/cluster/index.tsx` was far more useful than a plain rejection would 
have been.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to