fixed exception when resizing removed pattern