瀏覽代碼

Return the 'manuallyApprovesFollowers' actor field according to user configuration.

default 1 年之前
父節點
當前提交
35b35ec3af
共有 1 個文件被更改,包括 4 次插入 和 0 次删除
  1. 4 0
      activitypub.c

+ 4 - 0
activitypub.c

@@ -1287,6 +1287,10 @@ xs_dict *msg_actor(snac *snac)
         msg = xs_dict_set(msg, "alsoKnownAs", loaka);
     }
 
+    const xs_val *manually = xs_dict_get(snac->config, "approve_followers");
+    msg = xs_dict_set(msg, "manuallyApprovesFollowers",
+        xs_stock(xs_is_true(manually) ? XSTYPE_TRUE : XSTYPE_FALSE));
+
     return msg;
 }