Skip to content
This repository has been archived by the owner on May 6, 2024. It is now read-only.

Commit

Permalink
chore: fix warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
mumer92 committed Jul 11, 2023
1 parent 0d09231 commit 5deaa03
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 3 deletions.
9 changes: 7 additions & 2 deletions Source/DropDown/helpers/DPDUIView+Extension.swift
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,13 @@ internal extension UIView {
internal extension UIWindow {

static func visibleWindow() -> UIWindow? {
var currentWindow = UIApplication.shared.keyWindow

var currentWindow = UIApplication
.shared
.connectedScenes
.compactMap { $0 as? UIWindowScene }
.flatMap { $0.windows }
.first { $0.isKeyWindow }

if currentWindow == nil {
let frontToBackWindows = Array(UIApplication.shared.windows.reversed())

Expand Down
2 changes: 1 addition & 1 deletion Source/NewCourseContentController.swift
Original file line number Diff line number Diff line change
Expand Up @@ -244,7 +244,7 @@ extension NewCourseContentController: CourseContentPageViewControllerDelegate {
}

private func updateHeaderState(with controller: CourseContentPageViewController) {
if let controller = controller.viewControllers?.first as? VideoBlockViewController {
if let _ = controller.viewControllers?.first as? VideoBlockViewController {
if currentOrientation() != .portrait {
collapseHeaderView()
} else if headerViewState == .collapsed {
Expand Down

0 comments on commit 5deaa03

Please sign in to comment.