fix: cli feature compilation

This commit is contained in:
Kingtous 2022-06-27 12:09:27 +08:00
parent 0d9218eae7
commit d79bdd6afe
2 changed files with 2 additions and 1 deletions

View File

@ -21,7 +21,7 @@ pub trait FileManager: Interface {
#[cfg(any(target_os = "android", target_os = "ios", feature = "cli"))]
fn read_dir(&self, path: &str, include_hidden: bool) -> String {
use crate::flutter::make_fd_to_json;
use crate::common::make_fd_to_json;
match fs::read_dir(&fs::get_path(path), include_hidden) {
Ok(fd) => make_fd_to_json(fd),
Err(_) => "".into(),

View File

@ -441,6 +441,7 @@ pub fn is_installed_daemon(_prompt: bool) -> bool {
}
pub fn get_error() -> String {
#[cfg(not(any(feature = "cli")))]
#[cfg(target_os = "linux")]
{
let dtype = crate::platform::linux::get_display_server();