Skip to content

Commit

Permalink
update field
Browse files Browse the repository at this point in the history
  • Loading branch information
huangminlinux committed Mar 30, 2018
1 parent 7ef2e6a commit 20842f7
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/ios/Plugins/JMessagePlugin.m
Original file line number Diff line number Diff line change
Expand Up @@ -980,10 +980,10 @@ - (void)getHistoryMessages:(CDVInvokedUrlCommand *)command {
limit = nil;
}

BOOL isDecend = false;
if (param[@"isDecend"]) {
NSNumber *number = param[@"isDecend"];
isDecend = [number boolValue];
BOOL isDescend = false;
if (param[@"isDescend"]) {
NSNumber *number = param[@"isDescend"];
isDescend = [number boolValue];
}

NSArray *messageList = [conversation messageArrayFromNewestWithOffset:param[@"from"] limit:limit];
Expand All @@ -993,7 +993,7 @@ - (void)getHistoryMessages:(CDVInvokedUrlCommand *)command {
return [message messageToDictionary];
}];

if (isDecend) {
if (isDescend) {
messageDicArr = [[messageDicArr reverseObjectEnumerator] allObjects];
}

Expand Down

0 comments on commit 20842f7

Please sign in to comment.