Simplifiable conditional expression. (#941)
This commit is contained in:
parent
ef68684cb3
commit
3087acb929
|
@ -101,7 +101,7 @@ final class MemberUtils {
|
|||
* @return {@code true} if {@code m} is accessible
|
||||
*/
|
||||
static boolean isAccessible(final Member member) {
|
||||
return member != null && isPublic(member) && !member.isSynthetic();
|
||||
return isPublic(member) && !member.isSynthetic();
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -165,7 +165,7 @@ public class Streams {
|
|||
|
||||
@Override
|
||||
public boolean tryAdvance(final Consumer<? super T> action) {
|
||||
return enumeration.hasMoreElements() ? next(action) : false;
|
||||
return enumeration.hasMoreElements() && next(action);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue