diff --git a/hasjob/views/index.py b/hasjob/views/index.py index 937e8e266..88104bc59 100644 --- a/hasjob/views/index.py +++ b/hasjob/views/index.py @@ -743,7 +743,11 @@ def sitemap(key): ' \n' if authorized_sitemap: # Add domains to sitemap - for domain in Domain.query.filter(Domain.title != None).order_by('updated_at desc').all(): # NOQA + for domain in Domain.query.filter( + Domain.title != None, + Domain.description != None, + Domain.description != '' + ).order_by('updated_at desc').all(): # NOQA sitemapxml += ' \n'\ ' %s\n' % domain.url_for(_external=True) + \ ' %s\n' % (domain.updated_at.isoformat() + 'Z') + \