diff --git a/Signal/src/ViewControllers/ConversationView/ConversationInputToolbar.m b/Signal/src/ViewControllers/ConversationView/ConversationInputToolbar.m index 37b768297..fd34c1cd4 100644 --- a/Signal/src/ViewControllers/ConversationView/ConversationInputToolbar.m +++ b/Signal/src/ViewControllers/ConversationView/ConversationInputToolbar.m @@ -878,10 +878,6 @@ const CGFloat kMaxTextViewHeight = 98; [self ensureShouldShowVoiceMemoButtonAnimated:YES doLayout:YES]; [self updateHeightWithTextView:textView]; [self updateInputLinkPreview]; - - if (textView.text.ows_stripped.length < 1) { - [OWSLinkPreview clearLinkPreviewCache]; - } } - (void)textViewDidChangeSelection:(UITextView *)textView diff --git a/Signal/src/ViewControllers/ConversationView/ConversationViewController.m b/Signal/src/ViewControllers/ConversationView/ConversationViewController.m index 614d73f7c..0002ac339 100644 --- a/Signal/src/ViewControllers/ConversationView/ConversationViewController.m +++ b/Signal/src/ViewControllers/ConversationView/ConversationViewController.m @@ -2752,8 +2752,6 @@ typedef enum : NSUInteger { AudioServicesPlaySystemSound(soundId); } [self.typingIndicators didSendOutgoingMessageInThread:self.thread]; - - [OWSLinkPreview clearLinkPreviewCache]; } #pragma mark UIDocumentMenuDelegate diff --git a/Signal/src/ViewControllers/HomeView/HomeViewController.m b/Signal/src/ViewControllers/HomeView/HomeViewController.m index 7ceb701b8..3806974b9 100644 --- a/Signal/src/ViewControllers/HomeView/HomeViewController.m +++ b/Signal/src/ViewControllers/HomeView/HomeViewController.m @@ -709,8 +709,6 @@ typedef NS_ENUM(NSInteger, HomeViewControllerSection) { [self.searchResultsController viewDidAppear:animated]; self.hasEverAppeared = YES; - - [OWSLinkPreview clearLinkPreviewCache]; } - (void)viewDidDisappear:(BOOL)animated diff --git a/SignalServiceKit/src/Messages/Interactions/OWSLinkPreview.swift b/SignalServiceKit/src/Messages/Interactions/OWSLinkPreview.swift index 231b9995b..9f52e3ad4 100644 --- a/SignalServiceKit/src/Messages/Interactions/OWSLinkPreview.swift +++ b/SignalServiceKit/src/Messages/Interactions/OWSLinkPreview.swift @@ -551,13 +551,6 @@ public class OWSLinkPreview: MTLModel { } } - @objc - public class func clearLinkPreviewCache() { - return serialQueue.async { - linkPreviewDraftCache = nil - } - } - @objc public class func tryToBuildPreviewInfoObjc(previewUrl: String?) -> AnyPromise { return AnyPromise(tryToBuildPreviewInfo(previewUrl: previewUrl))