From 57a37d53461a07eebf391f9f3a8b41d7f6fcbdb5 Mon Sep 17 00:00:00 2001 From: Romain Forlot Date: Wed, 23 Aug 2017 10:57:13 +0200 Subject: Format: Remove spaces at EOL Change-Id: I50bbf17cfa913b40caf0cb6752a902fb626ec1ad Signed-off-by: Romain Forlot --- conf.d/project/lua.d/onload-daemon-01-init.lua | 10 +++++----- conf.d/project/lua.d/onload-daemon-03-controls.lua | 2 +- conf.d/project/lua.d/onload-daemon-10-event.lua | 4 ++-- 3 files changed, 8 insertions(+), 8 deletions(-) (limited to 'conf.d/project/lua.d') diff --git a/conf.d/project/lua.d/onload-daemon-01-init.lua b/conf.d/project/lua.d/onload-daemon-01-init.lua index ebdc678..26ff08a 100644 --- a/conf.d/project/lua.d/onload-daemon-01-init.lua +++ b/conf.d/project/lua.d/onload-daemon-01-init.lua @@ -21,7 +21,7 @@ _Global_Context={} --[[ This function is call during controller init phase as describe in onload-daemon-sample.json It receives two argument 1st one is the source (here on load) second one is the arguments - as expose in config file. + as expose in config file. In this sample we create an event that take the name of args["zzzz"], the resulting handle is save into _Global_Context for further use. @@ -32,17 +32,17 @@ _Global_Context={} function _Sample_Controller_Init(source, control) printf ("[-- Sample_Controller_Init --] source=%d control=%s", source, Dump_Table(control)) - + -- if no argument return now - if (control==nil or control["zzzz"]==nil) then + if (control==nil or control["zzzz"]==nil) then printf ("[-- Sample_Controller_Init --] no event name given") return end -- set a count to make more visible each call _Global_Context["counter"]=0 - + -- just for fun create an event _Global_Context["event"]=AFB:evtmake(control["zzzz"]) -end +end diff --git a/conf.d/project/lua.d/onload-daemon-03-controls.lua b/conf.d/project/lua.d/onload-daemon-03-controls.lua index f65c019..e9c8b51 100644 --- a/conf.d/project/lua.d/onload-daemon-03-controls.lua +++ b/conf.d/project/lua.d/onload-daemon-03-controls.lua @@ -15,7 +15,7 @@ limitations under the License. Following function are called when a client activate a control with - controller api -> APi=control VERB=dispatch + controller api -> APi=control VERB=dispatch arguments are - source (0) when requesting the control (-1) when releasing - control comme from config given with 'args' in onload-middlename-xxxxx.json diff --git a/conf.d/project/lua.d/onload-daemon-10-event.lua b/conf.d/project/lua.d/onload-daemon-10-event.lua index c0b21f9..474ebe0 100644 --- a/conf.d/project/lua.d/onload-daemon-10-event.lua +++ b/conf.d/project/lua.d/onload-daemon-10-event.lua @@ -45,7 +45,7 @@ function _Simple_Timer_Test (request, client) -- if event does not exit create it now. if (_MyContext["event"] == nil) then _MyContext["event"]= AFB:evtmake(client["label"]) - end + end -- if delay not defined default is 5s if (client["delay"]==nil) then client["delay"]=5000 end @@ -67,7 +67,7 @@ function _Simple_Timer_Test (request, client) -- settimer take a table with delay+count as input (count==0 means infinite) AFB:timerset (myTimer, "_Timer_Test_CB", context) - -- nothing special to return send back + -- nothing special to return send back AFB:success (request, myTimer) return 0 -- cgit 1.2.3-korg