mirror of https://github.com/zulip/zulip.git
8530ed0b5e
On the "Organization settings" page, we had two Save buttons for admins that had identical markup. This was confusing for people reading the code. Now the two buttons have different markup and individual, targeted click handlers (albeit still calling the same function to do most of the work). The context of this fix is that I was debugging a Casper flake where our Casper tests were essentially clicking on the same button twice. Depending on the timing, the second button click could cause a "No changes saved!" behavior that confused the Casper test. It is unclear whether Casper was clicking both buttons here (in which case this fix is necessary) or the same button twice (in which case this fix just removes a nasty red herring for debugging). The code still has the flaw that both buttons basically submit the same data to the server, despite the appearance on the page that there are two forms. The best fix for that is probably just to move the Language/Notifications stuff to another panel. I wanted to avoid touching this code altogether, but the minor modifications here were necessary to improve the Capser testing situation. |
||
---|---|---|
.. | ||
casper_lib | ||
casper_tests | ||
node_tests | ||
zjsunit | ||
.eslintrc.json | ||
run-casper |