Remove unused parameter

This commit is contained in:
René Pfeuffer
2018-06-26 08:55:52 +02:00
parent 651a8783c5
commit 4f52825875
2 changed files with 2 additions and 2 deletions

View File

@@ -29,7 +29,7 @@ class ResourceManagerAdapter<T extends ModelObject, D extends HalRepresentation,
return Response.ok(dto).build(); return Response.ok(dto).build();
} }
public Response update(String id, D dto, Function<T, T> mapper) { public Response update(String id, Function<T, T> mapper) {
T existingEntity = manager.get(id); T existingEntity = manager.get(id);
T changedEntity = mapper.apply(existingEntity); T changedEntity = mapper.apply(existingEntity);
return update(id, changedEntity); return update(id, changedEntity);

View File

@@ -74,7 +74,7 @@ public class UserResource {
}) })
@TypeHint(TypeHint.NO_CONTENT.class) @TypeHint(TypeHint.NO_CONTENT.class)
public Response update(@Context UriInfo uriInfo, @PathParam("id") String name, UserDto userDto) { public Response update(@Context UriInfo uriInfo, @PathParam("id") String name, UserDto userDto) {
return adapter.update(name, userDto, existing -> dtoToUserMapper.map(userDto, existing.getPassword())); return adapter.update(name, existing -> dtoToUserMapper.map(userDto, existing.getPassword()));
} }
/** /**