public GridFsResource getResource(String location) { return Optional.ofNullable(findOne(query(whereFilename().is(location)))) // .map(this::getResource) // .orElseGet(() -> GridFsResource.absent(location)); }
public GridFsResource getResource(String location) { return Optional.ofNullable(findOne(query(whereFilename().is(location)))) // .map(this::getResource) // .orElseGet(() -> GridFsResource.absent(location)); }