diff --git a/src/httpd.js.c b/src/httpd.js.c index 16401dbd..cb79af12 100644 --- a/src/httpd.js.c +++ b/src/httpd.js.c @@ -195,7 +195,7 @@ static void _httpd_callback_internal(tf_http_request_t* request, bool is_websock } JSValue client = JS_NewObject(context); - JS_SetPropertyStr(context, client, "tls", JS_FALSE); + JS_SetPropertyStr(context, client, "tls", request->is_tls ? JS_TRUE : JS_FALSE); JS_SetPropertyStr(context, request_object, "client", client); JSValue response_object = JS_NewObjectClass(context, _httpd_request_class_id);