瀏覽代碼

fix user block

tags/v1.0.0
Jonathan Cobb 4 年之前
父節點
當前提交
57274c4370
共有 1 個文件被更改,包括 4 次插入2 次删除
  1. +4
    -2
      bubble-server/src/main/resources/bubble/rule/social/block/JsUserBlockerRuleDriver.js.hbs

+ 4
- 2
bubble-server/src/main/resources/bubble/rule/social/block/JsUserBlockerRuleDriver.js.hbs 查看文件

@@ -80,8 +80,10 @@ function {{JS_PREFIX}}_update_user (author, do_block) {

function {{JS_PREFIX}}_block_user (author) {
const index = {{JS_PREFIX}}_blocked_users.indexOf(author);
if (index !== -1) {{JS_PREFIX}}_blocked_users.push(author);
{{JS_PREFIX}}_update_user(author, true);
if (index === -1) {
{{JS_PREFIX}}_blocked_users.push(author);
{{JS_PREFIX}}_update_user(author, true);
}
}

function {{JS_PREFIX}}_unblock_user (author) {


Loading…
取消
儲存