mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-11-30 19:58:39 +00:00
Fix extension check code to be iOS 6/7 compatible
This commit is contained in:
parent
2040206101
commit
4f05060adb
@ -265,7 +265,7 @@ BOOL bit_isRunningInAppExtension(void) {
|
||||
static dispatch_once_t checkAppExtension;
|
||||
|
||||
dispatch_once(&checkAppExtension, ^{
|
||||
isRunningInAppExtension = [[[NSBundle mainBundle] executablePath] containsString:@".appex/"];
|
||||
isRunningInAppExtension = ([[[NSBundle mainBundle] executablePath] rangeOfString:@".appex/"].location != NSNotFound);
|
||||
});
|
||||
|
||||
return isRunningInAppExtension;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user