body function for checking