今天遇到的问题,ResponseBody返回值不是String,而是一个页面,求解啊!!!!!

@RequestMapping(value = "/login.html", method = RequestMethod.POST)
@ResponseBody

public String login(String password, String email, HttpSession session,

HttpServletRequest request) throws Exception
{
User user = userService.getUser(email);
if (user == null)
{
return "wrong_email";
}

}

这段代码返回值,按道理当user==null的时候返回的post结果是个String值,wrong_email,

但是,我console的结果却是登录页面,

我很不解,不知道不是说ResponseBody用的不当还是什么问题

原文地址:https://www.cnblogs.com/dayu007/p/7613151.html