revert infoDictionary method in NSBundle hook

This commit is contained in:
aricloverEXTRA 2026-02-23 00:08:06 -06:00 committed by GitHub
parent d4f8cf0cc0
commit b49c27ea7e
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -8,18 +8,8 @@
- (NSDictionary *)infoDictionary {
NSDictionary *orig = %orig;
if ([self isEqual:NSBundle.mainBundle]) {
NSArray<NSString *> *stack = [NSThread callStackSymbols];
BOOL needsSpoof = NO;
for (NSString *frame in stack) {
if ([frame containsString:@"GIDSignIn"] ||
[frame containsString:@"GTMSessionFetcher"] ||
[frame containsString:@"GoogleSignIn"]) {
needsSpoof = YES;
break;
}
}
if (needsSpoof) {
NSMutableDictionary *patched = [orig mutableCopy];
NSMutableDictionary *patched = [orig mutableCopy];
if (patched) {
patched[@"CFBundleIdentifier"] = @"com.google.ios.youtube";
return [patched copy];
}