Skip to content

Commit

Permalink
simplify specification
Browse files Browse the repository at this point in the history
Signed-off-by: Kirill Mokevnin <[email protected]>
  • Loading branch information
mokevnin committed Oct 14, 2023
1 parent 0b942f3 commit da518c7
Showing 1 changed file with 1 addition and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,7 @@
@Component
public class PostCommentSpecification {
public Specification<PostComment> build(PostCommentParamsDTO params) {
Specification<PostComment> spec = Specification.where(null);
return spec
.and(withPostId(params.getPostId()))
return withPostId(params.getPostId())
.and(withCreatedAtGt(params.getCreatedAtGt()));
}

Expand Down

0 comments on commit da518c7

Please sign in to comment.