fix duplicate shape problem