Skip to content

Commit

Permalink
Don't try to fetch title if it's obviously an image.
Browse files Browse the repository at this point in the history
  • Loading branch information
foldericon committed Jul 17, 2014
1 parent 0afe3f9 commit ff9f243
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions Classes/TXURLDumper.m
Original file line number Diff line number Diff line change
Expand Up @@ -183,6 +183,13 @@ - (void)didPostNewMessageForViewController:(TVCLogController *)logController

if(errCode == 0) {
if(self.resolveShortURLsEnabled || self.getTitlesEnabled) {
if([[urlString lowercaseString] hasSuffix:@".jpg"] || [[urlString lowercaseString] hasSuffix:@".png"]) {
if(self.debugModeEnabled) {
NSString *log = [NSString stringWithFormat:@"URL: %@ has been dumped.", urlString];
[client printDebugInformationToConsole:log];
}
return;
}
TXHTTPHelper *http = [[TXHTTPHelper alloc] init];
[http setDelegate:self];
[http setCompletionBlock:^(NSError *error) {
Expand Down

0 comments on commit ff9f243

Please sign in to comment.