add some check code