source-dialog: avoid unneeded comparisons
Sources are unique, so the comparison can be avoided once the source is found
This commit is contained in:
@@ -281,7 +281,10 @@ add_source (GcalManager *manager,
|
|||||||
for (l = children; l != NULL; l = l->next)
|
for (l = children; l != NULL; l = l->next)
|
||||||
{
|
{
|
||||||
if (g_object_get_data (l->data, "source") == source)
|
if (g_object_get_data (l->data, "source") == source)
|
||||||
contains_source = TRUE;
|
{
|
||||||
|
contains_source = TRUE;
|
||||||
|
break;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!contains_source)
|
if (!contains_source)
|
||||||
|
|||||||
Reference in New Issue
Block a user