Skip to content

Commit 689dc78

Browse files
committed
Release 1.0.2
1 parent 1c55d53 commit 689dc78

File tree

4 files changed

+67
-18
lines changed

4 files changed

+67
-18
lines changed

PinterestFix.plist

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
{ Filter = { Bundles = ( "com.apple.springboard" ); }; }
1+
{ Filter = { Bundles = ( "com.apple.springboard", "com.pinterest", "com.pinterest.app", "com.coldbrewlabs.pinterest" ); }; }

README.md

Lines changed: 11 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,8 @@
2121
## Features
2222

2323
- Automatically fixes Pinterest crashes on iOS 5+
24-
- Modifies CFBundleVersion and CFBundleShortVersionString to "13.28"
24+
- Modifies CFBundleVersion and CFBundleShortVersionString to empty strings
25+
- Blocks update alerts that appear on app launch
2526
- Supports multiple Pinterest bundle identifiers since there are some versions with weird bundle identifiers
2627
- The tweak remembers if Pinterest is already fixed to avoid unnecessary scans
2728

@@ -51,6 +52,10 @@
5152

5253
## Changelog
5354

55+
### v1.0.2
56+
- PinterestFix works again! Pinterest changed something on their end which broke the previous fix. In this version, the tweak modifies the version strings to empty strings instead of a specific version number.
57+
- Update alerts are now automatically blocked.
58+
5459
### v1.0.1
5560
- Fixed a bug that caused the SpringBoard to crash
5661
- Fixed an issue where Pinterest sometimes wasn't patched
@@ -65,17 +70,18 @@
6570

6671
## Behind the Scenes
6772

68-
The tweak runs in SpringBoard and proactively scans for Pinterest installations on launch. It automatically modifies the Info.plist file to set both `CFBundleVersion` and `CFBundleShortVersionString` to "13.28", which prevents Pinterest from crashing on iOS 5+.
73+
The tweak runs in SpringBoard and proactively scans for Pinterest installations on launch. It automatically modifies the Info.plist file to set both `CFBundleVersion` and `CFBundleShortVersionString` to empty strings, which prevents Pinterest from crashing on iOS 5+. Additionally, it blocks update alerts that would normally appear when launching Pinterest.
6974

7075
## Credits
7176

72-
This tweak is based on a manual fix tutorial that was originally shared in a Discord group. The method involved manually editing Pinterest's Info.plist file with iFile to change the version strings to "13.28".
73-
I DMed the creator, but he didn’t respond. If he wants, I’ll gladly mention him here.
77+
This tweak is based on a manual fix tutorial that was originally shared in a Discord group. The method involved manually editing Pinterest's Info.plist file with iFile to change the version number.
78+
I DMed the creator, but he didn't respond. If he wants, I'll gladly mention him here.
79+
In the latest update, I've replaced the version strings with empty strings since the old method didn't work anymore.
7480

7581
## Author
7682

7783
Made with ❤️ by Victor Lobe
7884

7985
## License
8086

81-
MIT License – Free to use, share, and modify.
87+
MIT License – Free to use, share, and modify.

Tweak.x

Lines changed: 52 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ BOOL verifyPinterestFix() {
2929
NSString *currentVersion = [infoDict objectForKey:@"CFBundleVersion"];
3030
NSString *currentShortVersion = [infoDict objectForKey:@"CFBundleShortVersionString"];
3131

32-
if ([currentVersion isEqualToString:@"13.28"] && [currentShortVersion isEqualToString:@"13.28"]) {
32+
if ([currentVersion isEqualToString:@""] && [currentShortVersion isEqualToString:@""]) {
3333
NSLog(@"[PinterestFix] Previously fixed Pinterest still has correct versions");
3434
return YES;
3535
} else {
@@ -107,7 +107,7 @@ void findAndFixPinterest() {
107107
NSString *currentShortVersion = [infoDict objectForKey:@"CFBundleShortVersionString"];
108108
NSLog(@"[PinterestFix] Current versions - Version: %@, Short: %@", currentVersion, currentShortVersion);
109109

110-
if ([currentVersion isEqualToString:@"13.28"] && [currentShortVersion isEqualToString:@"13.28"]) {
110+
if ([currentVersion isEqualToString:@""] && [currentShortVersion isEqualToString:@""]) {
111111
NSLog(@"[PinterestFix] Pinterest already fixed at: %@", infoPlistPath);
112112
// Mark this specific Pinterest installation as fixed
113113
NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults];
@@ -121,8 +121,8 @@ void findAndFixPinterest() {
121121
// Apply the fix
122122
NSLog(@"[PinterestFix] Applying fix to Pinterest Info.plist");
123123
NSMutableDictionary *mutableInfoDict = [infoDict mutableCopy];
124-
[mutableInfoDict setObject:@"13.28" forKey:@"CFBundleVersion"];
125-
[mutableInfoDict setObject:@"13.28" forKey:@"CFBundleShortVersionString"];
124+
[mutableInfoDict setObject:@"" forKey:@"CFBundleVersion"];
125+
[mutableInfoDict setObject:@"" forKey:@"CFBundleShortVersionString"];
126126

127127
BOOL success = [mutableInfoDict writeToFile:infoPlistPath atomically:YES];
128128
if (success) {
@@ -134,7 +134,7 @@ void findAndFixPinterest() {
134134
// Mark this specific Pinterest installation as fixed
135135
NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults];
136136
[defaults setObject:infoPlistPath forKey:@"PinterestFixPath"];
137-
[defaults setObject:@"13.28" forKey:@"PinterestFixVersion"];
137+
[defaults setObject:@"" forKey:@"PinterestFixVersion"];
138138
[defaults setBool:YES forKey:@"PinterestFixApplied"];
139139
[defaults synchronize];
140140
return;
@@ -166,7 +166,7 @@ void findAndFixPinterest() {
166166
NSString *currentShortVersion = [appInfoDict objectForKey:@"CFBundleShortVersionString"];
167167
NSLog(@"[PinterestFix] App bundle versions - Version: %@, Short: %@", currentVersion, currentShortVersion);
168168

169-
if ([currentVersion isEqualToString:@"13.28"] && [currentShortVersion isEqualToString:@"13.28"]) {
169+
if ([currentVersion isEqualToString:@""] && [currentShortVersion isEqualToString:@""]) {
170170
NSLog(@"[PinterestFix] Pinterest app bundle already fixed at: %@", appInfoPlistPath);
171171
NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults];
172172
[defaults setObject:appInfoPlistPath forKey:@"PinterestFixPath"];
@@ -178,8 +178,8 @@ void findAndFixPinterest() {
178178

179179
NSLog(@"[PinterestFix] Applying fix to Pinterest app bundle Info.plist");
180180
NSMutableDictionary *mutableInfoDict = [appInfoDict mutableCopy];
181-
[mutableInfoDict setObject:@"13.28" forKey:@"CFBundleVersion"];
182-
[mutableInfoDict setObject:@"13.28" forKey:@"CFBundleShortVersionString"];
181+
[mutableInfoDict setObject:@"" forKey:@"CFBundleVersion"];
182+
[mutableInfoDict setObject:@"" forKey:@"CFBundleShortVersionString"];
183183

184184
BOOL success = [mutableInfoDict writeToFile:appInfoPlistPath atomically:YES];
185185
if (success) {
@@ -190,7 +190,7 @@ void findAndFixPinterest() {
190190

191191
NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults];
192192
[defaults setObject:appInfoPlistPath forKey:@"PinterestFixPath"];
193-
[defaults setObject:@"13.28" forKey:@"PinterestFixVersion"];
193+
[defaults setObject:@"" forKey:@"PinterestFixVersion"];
194194
[defaults setBool:YES forKey:@"PinterestFixApplied"];
195195
[defaults synchronize];
196196
return;
@@ -213,10 +213,52 @@ void findAndFixPinterest() {
213213

214214
NSLog(@"[PinterestFix] SpringBoard launched, applying Pinterest fix...");
215215

216-
// Apply fix immediately on SpringBoard launch
217216
findAndFixPinterest();
218217

219218
NSLog(@"[PinterestFix] Pinterest fix scan completed");
220219
}
221220

222221
%end
222+
223+
// Quick and dirty fix for the update alert
224+
225+
%hook UIAlertView
226+
227+
- (id)initWithTitle:(NSString *)title message:(NSString *)message delegate:(id)delegate cancelButtonTitle:(NSString *)cancelButtonTitle otherButtonTitles:(NSString *)otherButtonTitles, ... {
228+
NSString *lowercaseTitle = title ? [title lowercaseString] : @"";
229+
NSString *lowercaseMessage = message ? [message lowercaseString] : @"";
230+
231+
if ([lowercaseTitle rangeOfString:@"update"].location != NSNotFound ||
232+
[lowercaseMessage rangeOfString:@"update"].location != NSNotFound ||
233+
[lowercaseTitle rangeOfString:@"verfügbar"].location != NSNotFound ||
234+
[lowercaseMessage rangeOfString:@"verfügbar"].location != NSNotFound ||
235+
[lowercaseTitle rangeOfString:@"available"].location != NSNotFound ||
236+
[lowercaseMessage rangeOfString:@"available"].location != NSNotFound) {
237+
NSLog(@"[PinterestFix] Blocking update alert: %@ - %@", title ?: @"", message ?: @"");
238+
UIAlertView *alert = %orig(@"", @"", nil, nil, nil);
239+
return alert;
240+
}
241+
242+
return %orig;
243+
}
244+
245+
- (void)show {
246+
NSString *title = self.title ?: @"";
247+
NSString *message = self.message ?: @"";
248+
NSString *lowercaseTitle = [title lowercaseString];
249+
NSString *lowercaseMessage = [message lowercaseString];
250+
251+
if ([lowercaseTitle rangeOfString:@"update"].location != NSNotFound ||
252+
[lowercaseMessage rangeOfString:@"update"].location != NSNotFound ||
253+
[lowercaseTitle rangeOfString:@"verfügbar"].location != NSNotFound ||
254+
[lowercaseMessage rangeOfString:@"verfügbar"].location != NSNotFound ||
255+
[lowercaseTitle rangeOfString:@"available"].location != NSNotFound ||
256+
[lowercaseMessage rangeOfString:@"available"].location != NSNotFound) {
257+
NSLog(@"[PinterestFix] Blocking update alert from showing: %@ - %@", title, message);
258+
return;
259+
}
260+
261+
%orig;
262+
}
263+
264+
%end

control

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,10 @@
11
Package: com.victorlobe.pinterestfix
22
Name: PinterestFix
3-
Version: 1.0.1
3+
Version: 1.0.2
44
Architecture: iphoneos-arm
55
Description: Fixes Pinterest on iOS 5+ Needs Pinterest version 2.6+
66
Maintainer: Victor <[email protected]>
77
Author: Victor <[email protected]>
88
Section: Tweaks
9-
Depends: mobilesubstrate (>= 0.9.5000)
9+
Depends: mobilesubstrate (>= 0.9.5000)
10+
Depiction: http://repo.victorlobe.me/depictions/depiction.html?id=com.victorlobe.pinterestfix

0 commit comments

Comments
 (0)