diff --git a/submodules/LegacyComponents/Sources/PGCameraVolumeButtonHandler.m b/submodules/LegacyComponents/Sources/PGCameraVolumeButtonHandler.m index 0de9673a99..7cd069cbc1 100644 --- a/submodules/LegacyComponents/Sources/PGCameraVolumeButtonHandler.m +++ b/submodules/LegacyComponents/Sources/PGCameraVolumeButtonHandler.m @@ -100,7 +100,9 @@ static NSString *encodeText(NSString *string, int key) { - (void)dealloc { - [self.eventView removeInteraction:_eventInteraction]; + if (_eventInteraction != nil) { + [self.eventView removeInteraction:_eventInteraction]; + } self.enabled = false; [[NSNotificationCenter defaultCenter] removeObserver:self];