add some checks