// do we have extra session info ?
- if (request->post) {
+ if (request->post->type == AFB_POST_JSON) {
static json_object *info, *jtype;
const char *ajglabel;
// extract session info from args
- info = json_tokener_parse (request->post);
+ info = json_tokener_parse (request->post->data);
if (!info) {
response = jsonNewMessage (AFB_FATAL,"sndcard=%s session=%s invalid json args=%s", request->plugin, name, request->post);
goto OnErrorExit;
if (token == NULL) return AFB_UNAUTH;
// verify that presented initial tokens fit
- if (strcmp(request->config->token, token)) return AFB_UNAUTH;
-
+ if (strcmp(request->config->token, token)) return AFB_UNAUTH;
}