build: Fix.
This commit is contained in:
@@ -1202,7 +1202,14 @@ static JSValue _tf_ssb_swap_with_server_identity(JSContext* context, JSValueCons
|
|||||||
*work = (swap_with_server_identity_t) { 0 };
|
*work = (swap_with_server_identity_t) { 0 };
|
||||||
tf_ssb_whoami(ssb, work->server_id, sizeof(work->server_id));
|
tf_ssb_whoami(ssb, work->server_id, sizeof(work->server_id));
|
||||||
tf_string_set(work->user_id, sizeof(work->user_id), id);
|
tf_string_set(work->user_id, sizeof(work->user_id), id);
|
||||||
memcpy(work->user, user, user_length + 1);
|
if (user)
|
||||||
|
{
|
||||||
|
memcpy(work->user, user, user_length + 1);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
*work->user = '\0';
|
||||||
|
}
|
||||||
JSValue result = JS_NewPromiseCapability(context, work->promise);
|
JSValue result = JS_NewPromiseCapability(context, work->promise);
|
||||||
char description[1024];
|
char description[1024];
|
||||||
snprintf(description, sizeof(description), "Swap identity %s with %s.", work->user_id, work->server_id);
|
snprintf(description, sizeof(description), "Swap identity %s with %s.", work->user_id, work->server_id);
|
||||||
|
|||||||
Reference in New Issue
Block a user