From e16eb980016b370f16bb8315434152decc1239b3 Mon Sep 17 00:00:00 2001
From: Vitaly Takmazov
Date: Sun, 24 Mar 2019 11:36:47 +0300
Subject: Cleanup unused code
---
Juick/Main.storyboard | 4 ++--
Juick/ViewControllers/MessagesViewController.h | 1 -
Juick/ViewControllers/MessagesViewController.m | 24 +-----------------------
3 files changed, 3 insertions(+), 26 deletions(-)
(limited to 'Juick')
diff --git a/Juick/Main.storyboard b/Juick/Main.storyboard
index 9bb775d..2438017 100644
--- a/Juick/Main.storyboard
+++ b/Juick/Main.storyboard
@@ -365,7 +365,7 @@
-
+
@@ -415,7 +415,7 @@
-
+
diff --git a/Juick/ViewControllers/MessagesViewController.h b/Juick/ViewControllers/MessagesViewController.h
index 8f41af7..c8eb4cf 100644
--- a/Juick/ViewControllers/MessagesViewController.h
+++ b/Juick/ViewControllers/MessagesViewController.h
@@ -12,7 +12,6 @@
extern NSString* const messageCellIdentifier;
@protocol MessagesDelegate
--(void) didReceiveChallenge;
-(void) loadMore;
@end
diff --git a/Juick/ViewControllers/MessagesViewController.m b/Juick/ViewControllers/MessagesViewController.m
index 88bee93..57087d7 100644
--- a/Juick/ViewControllers/MessagesViewController.m
+++ b/Juick/ViewControllers/MessagesViewController.m
@@ -33,11 +33,7 @@ NSString* const messageCellIdentifier = @"messageCell";
}
[[APIClient sharedClient] pullNextFromPath:self.path params:self.params callback:^(NSArray *next, NSError *err) {
if (err) {
- if ([err.domain isEqual: @"JuickErrorDomain"] && err.code == 401) {
- [self.messagesDelegate didReceiveChallenge];
- } else {
- [User throwUnableToLogin:self error:err];
- }
+ [User throwUnableToLogin:self error:err];
return;
}
NSArray *newMsgs = next;
@@ -141,24 +137,6 @@ NSString* const messageCellIdentifier = @"messageCell";
-(void) prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender {
/*
- NSNumber *mid;
- Message *msg = [self.messages objectAtIndex:[self.tableView indexPathForSelectedRow].row];
- BOOL scrollToEnd = NO;
- if ([AppDelegate shared].pushedThread != nil) {
- mid = [[AppDelegate shared].pushedThread copy];
- [AppDelegate shared].pushedThread = nil;
- [AppDelegate shared].pushedUname = nil;
- scrollToEnd = YES;
- } else {
- mid = msg.mid;
- }
- if ([mid integerValue] > 0) {
- ThreadViewController *threadVC = (ThreadViewController *)segue.destinationViewController;
- [threadVC setMessages:[@[msg] mutableCopy]];
- [threadVC setPath:[APIClient threadUrl]];
- [threadVC setParams:@{@"mid": mid }];
- [threadVC setShouldScrollToBottomOnRefresh:scrollToEnd];
- }
if ([segue.identifier isEqual: @"profileSegue"]) {
BlogViewController *blogVC = (BlogViewController *)segue.destinationViewController;
[blogVC setUname:self.selectedUser];
--
cgit v1.2.3