This commit is contained in:
Kovid Goyal 2012-06-19 18:28:45 +05:30
parent 02eb54c1d0
commit 957bd0512f

View File

@ -65,6 +65,9 @@ class DBPrefs(dict):
return default
def set_namespaced(self, namespace, key, val):
if u':' in key: raise KeyError('Colons are not allowed in keys')
if u':' in namespace: raise KeyError('Colons are not allowed in'
' the namespace')
key = u'namespaced:%s:%s'%(namespace, key)
self[key] = val