improved the checks