Commit bfbb13ad authored by yanzg's avatar yanzg

Merge branch 'ver1.1' of http://192.168.0.204/yzg/yzg-util

parents 495c56c6 99c14401
...@@ -1278,6 +1278,9 @@ public class StringHelper { ...@@ -1278,6 +1278,9 @@ public class StringHelper {
while (handle) { while (handle) {
handle = false; handle = false;
for (String prefix : suffix) { for (String prefix : suffix) {
if (StringHelper.isEmpty(prefix)) {
continue;
}
if (from.startsWith(prefix)) { if (from.startsWith(prefix)) {
from = from.substring(prefix.length()); from = from.substring(prefix.length());
handle = true; handle = true;
...@@ -1302,6 +1305,9 @@ public class StringHelper { ...@@ -1302,6 +1305,9 @@ public class StringHelper {
while (handle) { while (handle) {
handle = false; handle = false;
for (String prefix : suffix) { for (String prefix : suffix) {
if (StringHelper.isEmpty(prefix)) {
continue;
}
if (from.endsWith(prefix)) { if (from.endsWith(prefix)) {
from = from.substring(0, from.length() - prefix.length()); from = from.substring(0, from.length() - prefix.length());
handle = true; handle = true;
......
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