fix contest_edit warning

This commit is contained in:
undefined committed 2022-12-12 03:19:53 +08:00
1 parent f4127a806a
commit 3069271ecd
1 file changed
+1 -1
@@ -8,7 +8,7 @@ const page = new NamedPage(['contest_edit', 'contest_create', 'homework_create',
ProblemSelectAutoComplete.getOrConstruct($('[name="pids"]'), { multi: true, clearDefaultValue: false });
if (pagename.endsWith('edit')) {
let confirmed = false;
$(document).on('click', '[name="operation"]', (ev) => {
$(document).on('click', '[value="delete"]', (ev) => {
ev.preventDefault();
if (confirmed) {
return request.post('', { operation: 'delete' }).then((res) => {