From de8d102bc8dfa19387602481496d2e58b003300f Mon Sep 17 00:00:00 2001 From: "pengfei.zhou" Date: Thu, 15 Jul 2021 16:39:57 +0800 Subject: [PATCH] iOS: fix type error --- doric-iOS/Pod/Classes/Shader/DoricFlowLayoutNode.m | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/doric-iOS/Pod/Classes/Shader/DoricFlowLayoutNode.m b/doric-iOS/Pod/Classes/Shader/DoricFlowLayoutNode.m index 3c77848d..8bd8d695 100644 --- a/doric-iOS/Pod/Classes/Shader/DoricFlowLayoutNode.m +++ b/doric-iOS/Pod/Classes/Shader/DoricFlowLayoutNode.m @@ -91,10 +91,10 @@ - (NSArray *)layoutAttributesForElementsInRect:(CGRect)rect { - (UICollectionViewLayoutAttributes *)layoutAttributesForItemAtIndexPath:(NSIndexPath *)indexPath { NSNumber *minYOfColumn = @(0); NSArray *keys = self.columnHeightInfo.allKeys; - NSArray *sortedKeys = [keys sortedArrayUsingComparator:^NSComparisonResult(NSNumber * obj1, NSNumber *obj2) { + NSArray *sortedKeys = [keys sortedArrayUsingComparator:^NSComparisonResult(NSNumber *obj1, NSNumber *obj2) { return [obj1 intValue] <= [obj2 intValue] ? -1 : 1; }]; - + for (NSNumber *key in sortedKeys) { if ([self.columnHeightInfo[key] floatValue] < [self.columnHeightInfo[minYOfColumn] floatValue]) { minYOfColumn = key; @@ -164,7 +164,7 @@ @interface DoricFlowLayoutNode () = self.itemCount && self.onLoadMoreFuncId) { [self callLoadMore]; }