问题描述
我正在使用旧代码来通过JWT学习Spring Security。
我在这段代码上收到以下错误(特别是在@RequestBody上)
authenticateUser(@Value @RequestBody
“ loginRequest”){。 。 。
错误:语法错误,插入“ Type VariableDeclaratorId”以完成FormalParameterList
建议表示赞赏。谢谢。
代码:
@RestController
@RequestMapping("/bb/auth")
public class AuthController {
@Autowired
AuthenticationManager
authenticationManager;
@Autowired
UserRepository userRepository;
@Autowired
PasswordEncoder encoder;
@Autowired
JwtUtils jwtUtils;
LoginRequest loginRequest;
@PostMapping("/login")
public ResponseEntity<?>
authenticateUser(@Value @RequestBody
"loginRequest") { . . .}
解决方法
暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!
如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。
小编邮箱:dio#foxmail.com (将#修改为@)