fixed a problem of array/object in Check::valid