set method in realizations

This commit is contained in:
2020-11-18 20:27:29 +06:00
parent dd2fc5a86f
commit fcacdcd544
6 changed files with 54 additions and 3 deletions

View File

@@ -61,4 +61,13 @@ fun <Key, Value> Route.configureOneToManyWriteKeyValueRepoRoutes(
originalRepo.clear(key),
)
}
post(setRoute) {
val obj = call.uniload(keyValueMapSerializer)
call.unianswer(
Unit.serializer(),
originalRepo.set(obj)
)
}
}