diff options
| author | violette p. <vi@violette.town> | 2025-12-09 04:58:13 +0100 |
|---|---|---|
| committer | grunfink <grunfink@comam.es> | 2025-12-09 04:58:13 +0100 |
| commit | 4102a6a7ac7ab7c651fe0b03358148e8d15418cc (patch) | |
| tree | 9f8fe1daed0f20bf6f1c78318347851f86c12cb9 /mastoapi.c | |
| parent | c741c3078e4dcc0fcdda15f9082a87788383b61d (diff) | |
make webpush use our notification server vkey instead of a random, ill-formated
key (necessary for some client notifications, such as moshidon)
Diffstat (limited to 'mastoapi.c')
| -rw-r--r-- | mastoapi.c | 5 |
1 files changed, 4 insertions, 1 deletions
@@ -3044,7 +3044,10 @@ int mastoapi_post_handler(const xs_dict *req, const char *q_path, xs *app = xs_dict_new(); xs *id = xs_replace_i(tid(0), ".", ""); xs *csec = random_str(); - xs *vkey = random_str(); + char *vkey = (char *)xs_dict_get(srv_config, "vkey"); + if (vkey == NULL) + vkey = random_str(); + xs *cid = NULL; /* pick a non-existent random cid */ |