diff --git a/combo_plugin_gnm/management/commands/gnm_create_places.py b/combo_plugin_gnm/management/commands/gnm_create_places.py index c8c320d..99c023a 100644 --- a/combo_plugin_gnm/management/commands/gnm_create_places.py +++ b/combo_plugin_gnm/management/commands/gnm_create_places.py @@ -67,7 +67,7 @@ class Command(BaseCommand): page.title = Template(page_title_template).render(ctx) if not page.title: continue - page.parent = Page.objects.get(slug=layer.slug) + page.parent = Page.objects.get(slug=layer.slug, parent__isnull=False) page.template_name = 'place' page.save()