1. Steve Losh
  2. stoat

Commits

Daniel Jaouen  committed 37316df

getattr.

  • Participants
  • Parent commits 439a183
  • Branches default

Comments (0)

Files changed (1)

File stoat/search_indexes.py

View file
 
 from models import Page
 
-INDEX_CLASS = getattr(settings, 'STOAT_HAYSTACK_INDEX_CLASS')
+INDEX_CLASS = getattr(settings, 'STOAT_HAYSTACK_INDEX_CLASS', None)
 if INDEX_CLASS:
     module_name, index_name = INDEX_CLASS.rsplit('.', 1)
     module = __import__(module_name, fromlist=[index_name])