aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authordefault <nobody@localhost>2025-01-07 08:08:51 +0100
committerdefault <nobody@localhost>2025-01-07 08:08:51 +0100
commit64f2d3d746d8536c460b88fc852fdca01c5c813c (patch)
tree6141b84b9ddb58b43003cea309b20209b8d39164
parentb2bd4e18b9d7691cfae7be3e5e08a0c00ff4ac0e (diff)
Minor semantic tweak.
-rw-r--r--activitypub.c6
-rw-r--r--snac.h2
2 files changed, 6 insertions, 2 deletions
diff --git a/activitypub.c b/activitypub.c
index 1ae5ad9..0740d3d 100644
--- a/activitypub.c
+++ b/activitypub.c
@@ -1423,8 +1423,9 @@ xs_dict *msg_follow(snac *snac, const char *q)
xs_dict *msg_note(snac *snac, const xs_str *content, const xs_val *rcpts,
const xs_str *in_reply_to, const xs_list *attach,
- int priv, const char *lang_str)
+ int scope, const char *lang_str)
/* creates a 'Note' message */
+/* scope: 0, public; 1, private (mentioned only); 2, "quiet public"; 3, followers only */
{
xs *ntid = tid(0);
xs *id = xs_fmt("%s/p/%s", snac->actor, ntid);
@@ -1440,6 +1441,9 @@ xs_dict *msg_note(snac *snac, const xs_str *content, const xs_val *rcpts,
xs_list *p;
const xs_val *v;
+ /* FIXME: implement scopes 2 and 3 */
+ int priv = scope == 1;
+
if (rcpts == NULL)
to = xs_list_new();
else {
diff --git a/snac.h b/snac.h
index ec3ee5c..75db4a9 100644
--- a/snac.h
+++ b/snac.h
@@ -317,7 +317,7 @@ xs_dict *msg_follow(snac *snac, const char *actor);
xs_dict *msg_note(snac *snac, const xs_str *content, const xs_val *rcpts,
const xs_str *in_reply_to, const xs_list *attach,
- int priv, const char *lang);
+ int scope, const char *lang);
xs_dict *msg_undo(snac *snac, const xs_val *object);
xs_dict *msg_delete(snac *snac, const char *id);