mirror of
https://gitee.com/dromara/hutool.git
synced 2025-04-24 18:04:54 +08:00
!228 cn.hutool.core.collection.CollUtil#addAll(java.util.Collection<T>, java.lang.Iterable<T>) 判断空指针
Merge pull request !228 from jiangzeyin/v5-dev
This commit is contained in:
commit
0596112cf6
@ -2108,6 +2108,9 @@ public class CollUtil {
|
||||
* @return 原集合
|
||||
*/
|
||||
public static <T> Collection<T> addAll(Collection<T> collection, Iterable<T> iterable) {
|
||||
if (iterable == null) {
|
||||
return collection;
|
||||
}
|
||||
return addAll(collection, iterable.iterator());
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user