last commit

This commit is contained in:
Konstantin 2025-02-19 19:00:00 +03:00
parent 2fef942c52
commit 7292491328
2 changed files with 1 additions and 2 deletions

View File

@ -34,7 +34,7 @@ public class EmployeeController {
} }
// @PreAuthorize("hasAuthority('ROLE_ADMIN')") // @PreAuthorize("hasAuthority('ROLE_ADMIN')")
@PutMapping("/ban") @GetMapping("/ban")
public void ban(@RequestParam final String login) { public void ban(@RequestParam final String login) {
employeeService.banEmployee(login); employeeService.banEmployee(login);
} }

View File

@ -39,7 +39,6 @@ public class EmployeeServiceImpl implements EmployeeService {
@Override @Override
public Employee getEmployee(final String login) { public Employee getEmployee(final String login) {
var encoder = new BCryptPasswordEncoder();
if (!employeeRepository.existsByLogin(login)) { if (!employeeRepository.existsByLogin(login)) {
throw new EmployeeNotFoundException(); throw new EmployeeNotFoundException();
} }