Proper env variable check