def setup(): """ Gather all checks and validations """ from cms.plugin_pool import plugin_pool validate_dependencies() validate_settings() plugin_pool.validate_templates()
def setup(): """ Gather all checks and validations """ from cms.plugin_pool import plugin_pool plugin_pool.set_plugin_meta() validate_dependencies() validate_settings() plugin_pool.validate_templates()
def setup(): """ Gather all checks and validations """ from cms.plugin_pool import plugin_pool if DJANGO_1_6: # While setup is called both in all the Django versions only 1.6- # requires paching the AppCache. 1.7 provides a cleaner way to handle # this in AppConfig and thus the patching is left for older version only from django.db.models import loading old_get_models = loading.AppCache.get_models def get_models_patched(self, **kwargs): ret_value = old_get_models(self, **kwargs) plugin_pool.set_plugin_meta() return ret_value loading.AppCache.get_models = get_models_patched else: plugin_pool.set_plugin_meta() validate_dependencies() validate_settings() plugin_pool.validate_templates()