Small improvement

pull/187/head
M66B 4 years ago
parent 596aaf95c9
commit 62ff5f651f

@ -71,6 +71,7 @@ public class EntityAnswer implements Serializable {
}
if (fullName != null) {
fullName = fullName.trim();
if (fullName.startsWith("\""))
fullName = fullName.substring(1);
if (fullName.endsWith("\""))
@ -80,13 +81,12 @@ public class EntityAnswer implements Serializable {
String first = fullName;
String last = null;
if (fullName != null) {
fullName = fullName.trim();
int c = fullName.lastIndexOf(",");
int c = fullName.lastIndexOf(',');
if (c > 0) {
last = fullName.substring(0, c).trim();
first = fullName.substring(c + 1).trim();
} else {
c = fullName.lastIndexOf(" ");
c = fullName.lastIndexOf(' ');
if (c > 0) {
first = fullName.substring(0, c).trim();
last = fullName.substring(c + 1).trim();

Loading…
Cancel
Save