class UserController {

    @ApiOperation(value = "Delete habit")
    @ApiResponses(value = {
            @ApiResponse(code = 200, message = HttpStatuses.OK),
            @ApiResponse(code = 303, message = HttpStatuses.SEE_OTHER),
            @ApiResponse(code = 400, message = HttpStatuses.BAD_REQUEST),
            @ApiResponse(code = 403, message = HttpStatuses.FORBIDDEN)
    })
    @DeleteMapping("/{userId}/habit/{habitId}")
    public void deleteHabit(
            @ApiParam("Id habit of current user. Cannot be empty.")
            @PathVariable Long habitId,
            @ApiParam("Id of current user. Cannot be empty.")
            @PathVariable @CurrentUserId Long userId) {
        userService.deleteHabitByUserIdAndHabitDictionary(userId, habitId);
        ResponseEntity.status(HttpStatus.OK);
    }

}