Browse Source

just in case

pull/2321/head
Chris Lu 3 years ago
parent
commit
728ed21a80
  1. 3
      other/java/client/src/main/java/seaweedfs/client/SeaweedUtil.java

3
other/java/client/src/main/java/seaweedfs/client/SeaweedUtil.java

@ -29,6 +29,9 @@ public class SeaweedUtil {
} }
public static String[] toDirAndName(String fullpath) { public static String[] toDirAndName(String fullpath) {
if (fullpath == null) {
return new String[]{"/", ""};
}
if (fullpath.endsWith("/")) { if (fullpath.endsWith("/")) {
fullpath = fullpath.substring(0, fullpath.length() - 1); fullpath = fullpath.substring(0, fullpath.length() - 1);
} }

Loading…
Cancel
Save