mirror of
https://github.com/samsonjs/vdirsyncer.git
synced 2026-04-03 10:25:51 +00:00
Extra asserts
This commit is contained in:
parent
89119f0cda
commit
13925ed3d5
1 changed files with 2 additions and 0 deletions
|
|
@ -286,6 +286,8 @@ class _Component(object):
|
|||
self.props = new_lines
|
||||
|
||||
def __setitem__(self, key, val):
|
||||
assert isinstance(val, text_type)
|
||||
assert u'\n' not in val
|
||||
del self[key]
|
||||
line = u'{}:{}'.format(key, val)
|
||||
self.props.append(line)
|
||||
|
|
|
|||
Loading…
Reference in a new issue