Commit 39a72583 authored by Omkar Ingale's avatar Omkar Ingale

Resolved open connetion mailingListIC.java

parent 30040e1e
...@@ -310,7 +310,7 @@ public class MailingListIC extends ValidatorEJB { ...@@ -310,7 +310,7 @@ public class MailingListIC extends ValidatorEJB {
errorString = getErrorString("name", "SQLIM", userId); errorString = getErrorString("name", "SQLIM", userId);
break; break;
} }
if (!Name.matches("^[a-zA-Z]+$")) { if (!Name.matches("^[a-zA-Z ]+$")) {
errorString = getErrorString("name", "INVNAME", userId); errorString = getErrorString("name", "INVNAME", userId);
break; break;
} }
...@@ -335,7 +335,7 @@ public class MailingListIC extends ValidatorEJB { ...@@ -335,7 +335,7 @@ public class MailingListIC extends ValidatorEJB {
errorString = getErrorString("name", "ALLFIELD", userId); errorString = getErrorString("name", "ALLFIELD", userId);
break; break;
} }
if (!Name.matches("^[a-zA-Z]+$")) { if (!Name.matches("^[a-zA-Z ]+$")) {
errorString = getErrorString("name", "INVNAME", userId); errorString = getErrorString("name", "INVNAME", userId);
break; break;
} }
...@@ -362,10 +362,19 @@ public class MailingListIC extends ValidatorEJB { ...@@ -362,10 +362,19 @@ public class MailingListIC extends ValidatorEJB {
} catch (Exception e) { } catch (Exception e) {
BaseLogger.log("3", null, null, "MailingListPostSave : DOM :: In catch block"); BaseLogger.log("3", null, null, "MailingListPostSave : DOM :: In catch block");
} }
finally {
if (conn != null) {
try {
conn.close();
} catch (SQLException e) {
e.printStackTrace();
}
}
}
return errorString; return errorString;
} }
private String checkNull(String input) { private String checkNull(String input) {
if (input == null) { if (input == null) {
input = ""; input = "";
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment