diff -r 5e6d0969bb5d -r 9623d591efb9 plcopen/plcopen.py --- a/plcopen/plcopen.py Thu Jun 06 23:01:15 2013 +0200 +++ b/plcopen/plcopen.py Thu Jun 06 23:45:39 2013 +0200 @@ -1884,7 +1884,7 @@ def removecontentInstance(self, id): if self.content["name"] in ["LD","FBD","SFC"]: - element = self.instances_dict.get(id, None) + element = self.instances_dict.pop(id, None) if element is not None: self.content["value"].getcontent().remove(element) else: