From def73a2713adc746f69036c8a713fc95334b335e Mon Sep 17 00:00:00 2001 From: Peter Date: Fri, 7 Sep 2018 02:08:09 +0300 Subject: [PATCH] no message --- Display/ViewController.swift | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Display/ViewController.swift b/Display/ViewController.swift index 786152f0c9..c1a8b3b980 100644 --- a/Display/ViewController.swift +++ b/Display/ViewController.swift @@ -441,7 +441,7 @@ private func traceViewVisibility(view: UIView, rect: CGRect) -> Bool { if view.window == nil { return false } - if let index = siblings.firstIndex(of: view.layer) { + if let index = siblings.index(where: { $0 === view.layer }) { let viewFrame = view.convert(rect, to: superview) for i in (index + 1) ..< siblings.count { if siblings[i].frame.contains(viewFrame) {