Skip to content

Commit

Permalink
Possible fix for #586
Browse files Browse the repository at this point in the history
  • Loading branch information
scenee committed Feb 3, 2024
1 parent be2be99 commit 0e0f773
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions Sources/Controller.swift
Original file line number Diff line number Diff line change
Expand Up @@ -732,6 +732,7 @@ private var originalDismissImp: IMP?
private typealias DismissFunction = @convention(c) (AnyObject, Selector, Bool, (() -> Void)?) -> Void
extension FloatingPanelController {
private static let dismissSwizzling: Void = {
guard originalDismissImp == nil else { return }
let aClass: AnyClass! = UIViewController.self //object_getClass(vc)
if let originalMethod = class_getInstanceMethod(aClass, #selector(dismiss(animated:completion:))),
let swizzledImp = class_getMethodImplementation(aClass, #selector(__swizzled_dismiss(animated:completion:))) {
Expand Down

0 comments on commit 0e0f773

Please sign in to comment.