update to substringdelete