updated to return true or false