From fe041c5ae5c3b87f549cbd2b515d7fc7ffd098d1 Mon Sep 17 00:00:00 2001 From: Marcin Lulek Date: Wed, 20 Jul 2016 12:23:38 +0200 Subject: [PATCH] middleware: add the register plugin directive further up the config stack --- rhodecode/config/middleware.py | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/rhodecode/config/middleware.py b/rhodecode/config/middleware.py index 8319dad4..b64a2a69 100644 --- a/rhodecode/config/middleware.py +++ b/rhodecode/config/middleware.py @@ -227,6 +227,12 @@ def error_handler(exception, request): def includeme(config): settings = config.registry.settings + # plugin information + config.registry.rhodecode_plugins = {} + + config.add_directive( + 'register_rhodecode_plugin', register_rhodecode_plugin) + if asbool(settings.get('appenlight', 'false')): config.include('appenlight_client.ext.pyramid_tween') @@ -249,11 +255,6 @@ def includeme(config): # Set the default renderer for HTML templates to mako. config.add_mako_renderer('.html') - # plugin information - config.registry.rhodecode_plugins = {} - - config.add_directive( - 'register_rhodecode_plugin', register_rhodecode_plugin) # include RhodeCode plugins includes = aslist(settings.get('rhodecode.includes', [])) for inc in includes: