Skip to content

Commit 608e2da

Browse files
committed
WIP: Fixes crash, with functionality loss
The “isOrganicMedia” property was removed from the IGMedia class in v415 (pretty sure). This was causing the crashes on feed load. The “isInFeedRecommendation” property catches *some* of the posts, but the vast majority are not caught. Need to find a workaround to restore the functionality of the “hide suggested posts” feature.
1 parent 81926e9 commit 608e2da

2 files changed

Lines changed: 2 additions & 2 deletions

File tree

src/Features/Feed/HideFeedItems.xm

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ static NSArray *removeItemsInList(NSArray *list, BOOL isFeed) {
1111

1212
// Posts
1313
if (
14-
([obj isKindOfClass:%c(IGMedia)] && !((IGMedia *)obj).isOrganicMedia)
14+
([obj isKindOfClass:%c(IGMedia)] && ((IGMedia *)obj).isInFeedRecommendation)
1515
|| ([obj isKindOfClass:%c(IGFeedGroupHeaderViewModel)] && [[obj title] isEqualToString:@"Suggested Posts"])
1616
) {
1717
NSLog(@"[SCInsta] Removing suggested posts");

src/InstagramHeaders.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,7 @@
8484
@end
8585

8686
@interface IGMedia : NSObject
87-
@property(nonatomic, readonly) BOOL isOrganicMedia;
87+
@property(nonatomic, readonly) BOOL isInFeedRecommendation;
8888
@property(readonly) IGVideo *video;
8989
@property(readonly) IGPhoto *photo;
9090
@end

0 commit comments

Comments
 (0)