setpermissive should have opt has option
authorEmmanuel Garette <egarette@cadoles.com>
Wed, 28 Aug 2013 20:05:44 +0000 (22:05 +0200)
committerEmmanuel Garette <egarette@cadoles.com>
Wed, 28 Aug 2013 20:05:44 +0000 (22:05 +0200)
tiramisu/setting.py

index d6ee8ac..f8c1d37 100644 (file)
@@ -399,7 +399,9 @@ class Settings(object):
                                               "").format(opt_or_descr._name,
                                                          str(props)), props)
 
-    def setpermissive(self, permissive, path=None):
+    def setpermissive(self, permissive, opt=None, path=None):
+        if opt is not None and path is None:
+            path = self._get_opt_path(opt)
         if not isinstance(permissive, tuple):
             raise TypeError(_('permissive must be a tuple'))
         self._p_.setpermissive(path, permissive)