浏览代码

Fixed an error that made deleting the notification email address impossible.

grunfink 1 月之前
父节点
当前提交
461eb10b9b
共有 1 个文件被更改,包括 2 次插入 和 0 次删除
  1. 2 0
      html.c

+ 2 - 0
html.c

@@ -6087,6 +6087,8 @@ int html_post_handler(const xs_dict *req, const char *q_path,
         }
         if ((v = xs_dict_get(p_vars, "email")) != NULL)
             snac.config = xs_dict_set(snac.config, "email", v);
+        else
+            snac.config = xs_dict_del(snac.config, "email");
         if ((v = xs_dict_get(p_vars, "telegram_bot")) != NULL)
             snac.config = xs_dict_set(snac.config, "telegram_bot", v);
         if ((v = xs_dict_get(p_vars, "telegram_chat_id")) != NULL)