Skip to content
Snippets Groups Projects
Commit 0801a905 authored by Danny Auble's avatar Danny Auble
Browse files

ok this sort is correct ;)

parent ace4b870
No related branches found
No related tags found
No related merge requests found
...@@ -201,10 +201,10 @@ static int _sort_childern_list(local_assoc_t *local_a, local_assoc_t *local_b) ...@@ -201,10 +201,10 @@ static int _sort_childern_list(local_assoc_t *local_a, local_assoc_t *local_b)
/* check to see if this is a user association or an account. /* check to see if this is a user association or an account.
* We want the accounts at the bottom * We want the accounts at the bottom
*/ */
if(list_count(local_a->childern) && !list_count(local_b->childern)) if(local_a->assoc->user && !local_b->assoc->user)
return 1;
else if(!list_count(local_a->childern) && list_count(local_b->childern))
return -1; return -1;
else if(!local_a->assoc->user && local_b->assoc->user)
return 1;
diff = strcmp(local_a->sort_name, local_b->sort_name); diff = strcmp(local_a->sort_name, local_b->sort_name);
if (diff < 0) if (diff < 0)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment