forked from organicmaps/organicmaps
[ios] Minor code refactoring
This commit is contained in:
parent
59515ae9fd
commit
cc5619fbb5
1 changed files with 3 additions and 2 deletions
|
@ -666,8 +666,9 @@ static void onSearchResultCallback(search::Results const & results)
|
|||
}
|
||||
else
|
||||
{
|
||||
if ([self.wrapper suggestsCount])
|
||||
return indexPath.row < [self.wrapper suggestsCount] ? CellTypeSuggest : CellTypeResult;
|
||||
size_t const numSuggests = [self.wrapper suggestsCount];
|
||||
if (numSuggests)
|
||||
return indexPath.row < numSuggests ? CellTypeSuggest : CellTypeResult;
|
||||
else
|
||||
return indexPath.row == 0 ? CellTypeShowOnMap : CellTypeResult;
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue