Skip to content

Commit

Permalink
Merge pull request #16 from camdenfullmer/return-if-found
Browse files Browse the repository at this point in the history
Return early if the scroll view was found
  • Loading branch information
NicholasBellucci authored Oct 31, 2022
2 parents 0aba9e1 + d3f3f3b commit 9faa432
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions Sources/StatefulTabView/Helpers/TabBarCoordinator.swift
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,10 @@ private extension TabBarCoordinator {
var view: UIScrollView?

views.forEach {
guard view == nil else {
return
}

if let scrollView = $0 as? UIScrollView {
view = scrollView
} else {
Expand Down

0 comments on commit 9faa432

Please sign in to comment.