You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@allura.apache.org by je...@apache.org on 2015/04/16 17:43:58 UTC
[08/22] allura git commit: [#7869] only apply patches once. Note how
below the newrelic patch already avoids the issue
[#7869] only apply patches once. Note how below the newrelic patch already avoids the issue
Project: http://git-wip-us.apache.org/repos/asf/allura/repo
Commit: http://git-wip-us.apache.org/repos/asf/allura/commit/33dcb089
Tree: http://git-wip-us.apache.org/repos/asf/allura/tree/33dcb089
Diff: http://git-wip-us.apache.org/repos/asf/allura/diff/33dcb089
Branch: refs/heads/ib/6017
Commit: 33dcb089e5ff37b468f7003eb1a20cb9dab98b4b
Parents: 99ed956
Author: Dave Brondsema <db...@slashdotmedia.com>
Authored: Mon Apr 6 21:31:27 2015 +0000
Committer: Dave Brondsema <db...@slashdotmedia.com>
Committed: Mon Apr 6 21:31:27 2015 +0000
----------------------------------------------------------------------
Allura/allura/lib/patches.py | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/allura/blob/33dcb089/Allura/allura/lib/patches.py
----------------------------------------------------------------------
diff --git a/Allura/allura/lib/patches.py b/Allura/allura/lib/patches.py
index 19f91b3..2c363ea 100644
--- a/Allura/allura/lib/patches.py
+++ b/Allura/allura/lib/patches.py
@@ -26,8 +26,13 @@ import simplejson
from allura.lib import helpers as h
-
+_patched = False
def apply():
+ global _patched
+ if _patched:
+ return
+ _patched = True
+
old_lookup_template_engine = tg.decorators.Decoration.lookup_template_engine
@h.monkeypatch(tg.decorators.Decoration)