Compare commits

..

No commits in common. "2c12fc075f75862170006685e1d7be13698a5076" and "e66695cbff365dc87f1064f3287670ef638c24f7" have entirely different histories.

2 changed files with 1 additions and 4 deletions

View File

@ -30,8 +30,7 @@ public class NewsController {
}
@GetMapping("/{id}")
@JwtVerify
public ResponseEntity<News> getNewsPage(@PathVariable Long id, @RequestParam String token) {
public ResponseEntity<News> getNewsPage(@PathVariable Long id) {
try {
return new ResponseEntity<>(newsService.getNewsById(id), HttpStatus.OK);
} catch (EntityNotFoundException e) {

View File

@ -58,7 +58,6 @@ public class NewsService {
news.setContent(request.getContent());
news.setAuthor(request.getAuthor());
news.setImagePath(request.getImagePath());
news.setTenant(request.getTenant());
newsRepository.save(news);
}
@ -70,7 +69,6 @@ public class NewsService {
news.setContent(request.getContent());
news.setAuthor(request.getAuthor());
news.setImagePath(request.getImagePath());
news.setTenant(request.getTenant());
newsRepository.save(news);
}
}