minor refactor of server
Some checks failed
continuous-integration/drone/push Build is failing

This commit is contained in:
Torma Kristóf 2020-05-21 22:30:19 +02:00
parent 10d305689d
commit 81e1ef6b39
Signed by: tormakris
GPG Key ID: DC83C4F2C41B1047

View File

@ -97,8 +97,10 @@ class InputServiceServer {
val tag = UUID.randomUUID().toString() val tag = UUID.randomUUID().toString()
val currentApiObject = ApiObject(tag = tag, date = description!!.date, device_id = description!!.device_id)
transaction { transaction {
resultObjectService.addOne(ApiObject(tag = tag, date = description!!.date, device_id = description!!.device_id)) resultObjectService.addOne(currentApiObject)
} }
connection.confirmChannel { connection.confirmChannel {
@ -107,7 +109,7 @@ class InputServiceServer {
} }
} }
call.respond(resultObjectService.getAllInputObjects()) call.respond(currentApiObject)
} }
get("/sample/{tagID}") { get("/sample/{tagID}") {