simplify code 2

Simplify code in 
 - src/client/ot_otapi_ot.cpp
 - src/server/UserCommandProcessor.cpp