can pop an unexisted property

This commit is contained in:
Emmanuel Garette 2018-04-03 14:27:20 +02:00
parent cc58a3f5c3
commit 80881875b2
1 changed files with 4 additions and 3 deletions

View File

@ -683,6 +683,7 @@ class TiramisuContextProperty(TiramisuContext):
@count @count
def pop(self, prop): def pop(self, prop):
props = self.get() props = self.get()
if prop in props:
props.remove(prop) props.remove(prop)
self.set(frozenset(props)) self.set(frozenset(props))
self.config_bag.setting_properties = self.config_bag.config.cfgimpl_get_settings().get_context_properties() self.config_bag.setting_properties = self.config_bag.config.cfgimpl_get_settings().get_context_properties()