@Path("config")
@Produces(MediaType.APPLICATION_JSON)
public Response setConfigValues(JSONObject jsonObject) {
User currentUser = securityService.getCurrentUser();
try {
currentUser.appendToConfig(jsonObject);
userService.updateUser(currentUser);
return Response.ok(currentUser.getConfig()).build();
} catch (Exception e) {
return error(e.getMessage(), Response.status(Response.Status.BAD_REQUEST));
}