diff --git a/src/main/java/dk/kea/onav2ndproject_rest/JwtFilter.java b/src/main/java/dk/kea/onav2ndproject_rest/JwtFilter.java index e2c34cd..c94dd67 100644 --- a/src/main/java/dk/kea/onav2ndproject_rest/JwtFilter.java +++ b/src/main/java/dk/kea/onav2ndproject_rest/JwtFilter.java @@ -7,6 +7,7 @@ import jakarta.servlet.http.HttpServletResponse; import lombok.AllArgsConstructor; +import org.springframework.beans.factory.annotation.Autowired; import org.springframework.security.authentication.UsernamePasswordAuthenticationToken; import org.springframework.security.core.context.SecurityContextHolder; import org.springframework.security.core.userdetails.UserDetails; @@ -19,7 +20,9 @@ @AllArgsConstructor @Component public class JwtFilter extends OncePerRequestFilter { + @Autowired private JwtUserDetailsService userDetailsService; + @Autowired private JwtTokenManager jwtTokenManager; @Override protected void doFilterInternal(HttpServletRequest request,