Skip to content

Commit

Permalink
Small refactor code
Browse files Browse the repository at this point in the history
  • Loading branch information
Vlasosik committed Apr 17, 2024
1 parent b3d4bf6 commit 6ab7bb1
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
import org.springframework.stereotype.Service;

import java.util.List;

import java.util.Objects;
import java.util.UUID;

Expand All @@ -25,6 +24,7 @@ public class LinkService {
* @throws NullLinkPropertyException If the 'link' parameter is null.
*/
public Link save(Link link) {
if (Objects.isNull(link)) {
throw new NullLinkPropertyException();
}
return linkRepository.save(link);
Expand All @@ -40,6 +40,7 @@ public Link save(Link link) {
*/

public Link update(Link link) {
if (Objects.isNull(link)) {
throw new NullLinkPropertyException();
}

Expand Down

0 comments on commit 6ab7bb1

Please sign in to comment.