mirror of
https://gitee.com/chinabugotech/hutool.git
synced 2025-07-21 15:09:48 +08:00
fix IoUtil bug
This commit is contained in:
@@ -601,7 +601,7 @@ public class IoUtil {
|
||||
throw new IORuntimeException(e);
|
||||
}
|
||||
if (readLength > 0 && readLength < length) {
|
||||
byte[] b2 = new byte[length];
|
||||
byte[] b2 = new byte[readLength];
|
||||
System.arraycopy(b, 0, b2, 0, readLength);
|
||||
return b2;
|
||||
} else {
|
||||
|
@@ -675,7 +675,7 @@ public class Validator {
|
||||
* 验证是否为可用邮箱地址
|
||||
*
|
||||
* @param value 值
|
||||
* @return 否为可用邮箱地址
|
||||
* @return true为可用邮箱地址
|
||||
*/
|
||||
public static boolean isEmail(CharSequence value) {
|
||||
return isMatchRegex(EMAIL, value);
|
||||
|
@@ -121,7 +121,7 @@ public class TreeUtil {
|
||||
|
||||
/**
|
||||
* 获取ID对应的节点,如果有多个ID相同的节点,只返回第一个。<br>
|
||||
* 此方法只查找此节点及子节点,采用广度优先遍历。
|
||||
* 此方法只查找此节点及子节点,采用递归深度优先遍历。
|
||||
*
|
||||
* @param <T> ID类型
|
||||
* @param node 节点
|
||||
|
Reference in New Issue
Block a user