-[ECSlidingViewController notifyWhenInteractionChangesUsingBlock:]: unrecognized selector sent to instance
Asked Answered
B

1

5

I recently updated Xcode to version 11.3.1 and after that i am not able to run my application. I've been getting the following exception:

2020-02-11 16:13:04.767795-0600 UVM[5204:80616] -[ECSlidingViewController notifyWhenInteractionChangesUsingBlock:]: unrecognized selector sent to instance 0x7f8258016c00

2020-02-11 16:13:04.785346-0600 UVM[5204:80616] *** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '-[ECSlidingViewController notifyWhenInteractionChangesUsingBlock:]: unrecognized selector sent to instance 0x7f8258016c00'

It was working fine before i did the Xcode update. Can anyone help me how to fix this issue?

Bloodstain answered 11/2, 2020 at 22:18 Comment(0)
B
6

It looks like the following method was deprecated and it was the one throwing the exception during launch.

- (void)notifyWhenInteractionEndsUsingBlock:(void(^)(id<UIViewControllerTransitionCoordinatorContext>context))handler {
    self.coordinatorInteractionEnded = handler;
}

It was in ECSlidingViewController.m

If we comment out that method and add the following method the app is working fine again:

- (void)notifyWhenInteractionChangesUsingBlock:(nonnull void (^)(id<UIViewControllerTransitionCoordinatorContext> _Nonnull))handler {
    self.coordinatorInteractionEnded = handler;
}
Bloodstain answered 14/2, 2020 at 17:13 Comment(1)
Amazing, having the same issue. Appreciate sooooo much!!Stirk

© 2022 - 2024 — McMap. All rights reserved.