not isEmpty => nonEmpty

This commit is contained in:
Yik San Chan 2020-11-14 22:58:00 -08:00
parent 24d01a101a
commit e4d8843971

View file

@ -209,7 +209,7 @@ object ActorSelection {
def apply(anchorRef: ActorRef, elements: Iterable[String]): ActorSelection = { def apply(anchorRef: ActorRef, elements: Iterable[String]): ActorSelection = {
val compiled: immutable.IndexedSeq[SelectionPathElement] = elements.iterator val compiled: immutable.IndexedSeq[SelectionPathElement] = elements.iterator
.collect { .collect {
case x if !x.isEmpty => case x if x.nonEmpty =>
if ((x.indexOf('?') != -1) || (x.indexOf('*') != -1)) SelectChildPattern(x) if ((x.indexOf('?') != -1) || (x.indexOf('*') != -1)) SelectChildPattern(x)
else if (x == "..") SelectParent else if (x == "..") SelectParent
else SelectChildName(x) else SelectChildName(x)