CleanUp and reformatting Code.

This commit is contained in:
giuseppe.bueti 2016-02-08 16:08:15 +01:00
parent 37acdef2a7
commit 06bbf19265
1 changed files with 1 additions and 4 deletions

View File

@ -26,7 +26,6 @@ public class MovieCrudService {
return inventory.get(imdbId);
} else
return null;
}
@POST
@ -41,7 +40,6 @@ public class MovieCrudService {
}
inventory.put(movie.getImdbId(), movie);
return Response.status(Response.Status.CREATED).build();
}
@ -55,9 +53,9 @@ public class MovieCrudService {
if (null == inventory.get(movie.getImdbId())) {
return Response.status(Response.Status.NOT_MODIFIED).entity("Movie is not in the database.\nUnable to Update").build();
}
inventory.put(movie.getImdbId(), movie);
return Response.status(Response.Status.OK).build();
}
@DELETE
@ -80,7 +78,6 @@ public class MovieCrudService {
public List<Movie> listMovies() {
return inventory.values().stream().collect(Collectors.toCollection(ArrayList::new));
}
}