shop_config = Config.get_shop_config()
def _get_shop_config(cls):
"""Convenience method to get the current shop config"""
try:
shop_config = cls.objects.get(site=settings.SITE_ID)
except Config.DoesNotExist:
log.warning("No Shop Config found, using test shop config.")
shop_config = NullConfig()
return shop_config
get_shop_config = classmethod(_get_shop_config)