adding pre-flight checks