changes to bool check()