[BAEL-9021] - Fixed compilation error and uncommented module in parent pom.xml

This commit is contained in:
amit2103 2018-09-25 01:30:05 +05:30
parent a14104319f
commit df7794c382
2 changed files with 4 additions and 4 deletions

View File

@ -642,7 +642,7 @@
<module>spring-mobile</module>
<!-- <module>spring-mustache</module> --><!-- PMD voilation -->
<module>spring-mvc-simple</module>
<!-- <module>spring-mybatis</module> --><!-- Compilation failure -->
<module>spring-mybatis</module>
<module>spring-rest-hal-browser</module>
<module>spring-rest-shell</module>
<module>spring-rest-template</module>
@ -959,7 +959,7 @@
<module>spring-mobile</module>
<!-- <module>spring-mustache</module> --><!-- PMD voilation -->
<module>spring-mvc-simple</module>
<!-- <module>spring-mybatis</module> --><!-- Compilation failure -->
<module>spring-mybatis</module>
<module>spring-rest-hal-browser</module>
<module>spring-rest-shell</module>
<module>spring-rest-template</module>

View File

@ -31,7 +31,7 @@ public class StudentController {
@RequestMapping(value = "/signup", method = RequestMethod.POST)
public String signup(@Validated @ModelAttribute("student") Student student, BindingResult result, ModelMap model) {
if (studentService.getStudentByUserName(student.getUserName())) {
if (studentService.getStudentByUserName(student.getUserName()) != null) {
model.addAttribute("message", "User Name exists. Try another user name");
return "signup";
} else {
@ -50,7 +50,7 @@ public class StudentController {
@RequestMapping(value = "/login", method = RequestMethod.POST)
public String login(@ModelAttribute("studentLogin") StudentLogin studentLogin, BindingResult result, ModelMap model) {
boolean found = studentService.getStudentByLogin(studentLogin.getUserName(), studentLogin.getPassword());
boolean found = studentService.getStudentByLogin(studentLogin.getUserName(), studentLogin.getPassword()) != null;
if (found) {
return "success";
} else {