summaryrefslogtreecommitdiffstats
path: root/plugins/afm-main-plugin/afm-main-plugin.c
diff options
context:
space:
mode:
authorJosé Bollo <jose.bollo@iot.bzh>2016-03-30 14:36:11 +0200
committerJosé Bollo <jose.bollo@iot.bzh>2016-03-30 14:36:11 +0200
commit0a621f91ee673dd9182467a4ed649636dd0f2ba0 (patch)
treec1776fe1c048f7f4de576a20cb97107925d8973a /plugins/afm-main-plugin/afm-main-plugin.c
parent520bbafb30ce49b94b7825ff553d8cb5bda6d612 (diff)
renaming of field api
Change-Id: I41ffc32e86e1c8c0f86fb1b06c2f8054867a9bc2 Signed-off-by: José Bollo <jose.bollo@iot.bzh>
Diffstat (limited to 'plugins/afm-main-plugin/afm-main-plugin.c')
-rw-r--r--plugins/afm-main-plugin/afm-main-plugin.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/plugins/afm-main-plugin/afm-main-plugin.c b/plugins/afm-main-plugin/afm-main-plugin.c
index f07afdb1..0b6b8680 100644
--- a/plugins/afm-main-plugin/afm-main-plugin.c
+++ b/plugins/afm-main-plugin/afm-main-plugin.c
@@ -71,7 +71,7 @@ static struct json_object *embed(AFB_request *request, const char *tag, struct j
static struct json_object *call_void(AFB_request *request, AFB_PostItem *item)
{
- struct json_object *obj = jbus_call_sj_sync(jbus, request->api, "true");
+ struct json_object *obj = jbus_call_sj_sync(jbus, request->method, "true");
if (verbose)
fprintf(stderr, "(afm-main-plugin) call_void: true -> %s\n", obj ? json_object_to_json_string(obj) : "NULL");
request->errcode = obj ? MHD_HTTP_OK : MHD_HTTP_FAILED_DEPENDENCY;
@@ -91,7 +91,7 @@ static struct json_object *call_appid(AFB_request *request, AFB_PostItem *item)
request->errcode = MHD_HTTP_INTERNAL_SERVER_ERROR;
return NULL;
}
- obj = jbus_call_sj_sync(jbus, request->api, sid);
+ obj = jbus_call_sj_sync(jbus, request->method, sid);
if (verbose)
fprintf(stderr, "(afm-main-plugin) call_appid: %s -> %s\n", sid, obj ? json_object_to_json_string(obj) : "NULL");
free(sid);
@@ -107,7 +107,7 @@ static struct json_object *call_runid(AFB_request *request, AFB_PostItem *item)
request->errcode = MHD_HTTP_BAD_REQUEST;
return NULL;
}
- obj = jbus_call_sj_sync(jbus, request->api, id);
+ obj = jbus_call_sj_sync(jbus, request->method, id);
if (verbose)
fprintf(stderr, "(afm-main-plugin) call_runid: %s -> %s\n", id, obj ? json_object_to_json_string(obj) : "NULL");
request->errcode = obj ? MHD_HTTP_OK : MHD_HTTP_FAILED_DEPENDENCY;
@@ -174,7 +174,7 @@ static struct json_object *call_file__appid(AFB_request *request, AFB_PostItem *
if (0 >= asprintf(&query, "\"%s\"", filename))
request->errcode = MHD_HTTP_INTERNAL_SERVER_ERROR;
else {
- obj = jbus_call_sj_sync(jbus, request->api, query);
+ obj = jbus_call_sj_sync(jbus, request->method, query);
if (verbose)
fprintf(stderr, "(afm-main-plugin) call_file_appid: %s -> %s\n", query, obj ? json_object_to_json_string(obj) : "NULL");
free(query);