Created
November 22, 2019 19:31
-
-
Save MattNewberry/a967faf2e7a398a28156320d4c4d32ca to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/buyonetsy/Favorites/BOEFavoritesAndListsViewController.m b/buyonetsy/Favorites/BOEFavoritesAndListsViewController.m | |
index cf1abc0460..5a210231a4 100644 | |
--- a/buyonetsy/Favorites/BOEFavoritesAndListsViewController.m | |
+++ b/buyonetsy/Favorites/BOEFavoritesAndListsViewController.m | |
@@ -21,6 +21,7 @@ | |
@interface BOEFavoritesAndListsViewController() <BOEFavoritesRecommendationViewDelegate, BOEFavoritesRecommendationResourceDelegate> | |
@property (nonatomic, nullable) FavoritesRecommendationView *favsRecommendationsView; | |
+@property (nonatomic, strong) BOEFavoritesRecommendationResource * favsRecsResource; | |
@end | |
@@ -77,6 +78,8 @@ - (void)viewDidLoad { | |
[self.analyticsContext.viewRenderingMetrics startTimer]; | |
[self setUpFavoriteRecommentionView]; | |
+ | |
+ self.favsRecsResource = [[BOEFavoritesRecommendationResource alloc] init]; | |
} | |
- (void)viewDidAppear:(BOOL)animated { | |
@@ -147,17 +150,23 @@ - (NSString *)shareURL { | |
return self.metadata[@"share_url"]; | |
} | |
+- (void)loadMore { | |
+ [super loadMore]; | |
+} | |
+ | |
+- (void)loadModulesWithRefresh:(BOOL)shouldRefresh { | |
+ [super loadModulesWithRefresh:shouldRefresh]; | |
+ | |
+ if ([self.analyticsContext isFlagEnabled:@"BOERecommendationsInFavsAndLists"]) { | |
+ self.favsRecsResource.delegate = self; | |
+ [self.favsRecsResource load]; | |
+ } | |
+} | |
- (void)setUpFavoriteRecommentionView { | |
if (self.isShowingError) { | |
return; | |
} | |
- | |
- if ([self.analyticsContext isFlagEnabled:@"BOERecommendationsInFavsAndLists"]) { | |
- BOEFavoritesRecommendationResource * favsRecsResource = [[BOEFavoritesRecommendationResource alloc] init]; | |
- favsRecsResource.delegate = self; | |
- [favsRecsResource load]; | |
- } | |
} | |
- (void)didFinishLoadRecommendationResourceWithResponse:(BOEFavoritesRecommendationResponse *)response { |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment