# HG changeset patch
# User Laurent Bessard
# Date 1379510793 -7200
# Node ID 758801f4b296824c3e8c76f99ed9c6b9eaff5ad7
# Parent  177d7cd76a3e0a2cd181a9fd4946e98aa3fc1f9c
Fixed bug when removing block

diff -r 177d7cd76a3e -r 758801f4b296 plcopen/plcopen.py
--- a/plcopen/plcopen.py	Fri Sep 13 17:26:47 2013 +0200
+++ b/plcopen/plcopen.py	Wed Sep 18 15:26:33 2013 +0200
@@ -1625,7 +1625,7 @@
     
     def removecontentInstance(self, local_id):
         if self.content.getLocalTag() in ["LD","FBD","SFC"]:
-            instance = instance_by_id_xpath(self.content)
+            instance = instance_by_id_xpath(self.content, localId=local_id)
             if len(instance) > 0:
                 self.content.remove(instance[0])
             else: