mirror of
https://gitee.com/chinabugotech/hutool.git
synced 2025-07-21 15:09:48 +08:00
修复RandomUtil.randomInt,RandomUtil.randomLong边界问题
This commit is contained in:
@@ -249,7 +249,7 @@ public class RandomUtil {
|
||||
min++;
|
||||
}
|
||||
if (includeMax) {
|
||||
max--;
|
||||
max++;
|
||||
}
|
||||
return getRandom().nextInt(min, max);
|
||||
}
|
||||
@@ -322,7 +322,7 @@ public class RandomUtil {
|
||||
min++;
|
||||
}
|
||||
if (includeMax) {
|
||||
max--;
|
||||
max++;
|
||||
}
|
||||
return getRandom().nextLong(min, max);
|
||||
}
|
||||
|
Reference in New Issue
Block a user