added check of CLI mode