web/views/embedding.py
changeset 4083 3b285889b8e9
parent 4023 eae23c40627a
child 4252 6c4f109c2b03
--- a/web/views/embedding.py	Wed Dec 09 15:19:48 2009 +0100
+++ b/web/views/embedding.py	Wed Dec 09 15:47:01 2009 +0100
@@ -52,7 +52,7 @@
         if 'custom_css' in req.form:
             req.add_css(req.form['custom_css'])
         embedded_url = req.form['url']
-        allowed = self._cw.config['embed-allowed']
+        allowed = self._cw.vreg.config['embed-allowed']
         _ = req._
         if allowed is None or not allowed.match(embedded_url):
             body = '<h2>%s</h2><h3>%s</h3>' % (
@@ -82,7 +82,7 @@
     url = entity.embeded_url()
     if not url or not url.strip():
         return 0
-    allowed = entity.config['embed-allowed']
+    allowed = entity._cw.vreg.config['embed-allowed']
     if allowed is None or not allowed.match(url):
         return 0
     return 1