Переглянути джерело

Fix build errors in some feature configurations

timvisee 6 роки тому
батько
коміт
a58b15af7b
3 змінених файлів з 2 додано та 3 видалено
  1. 0 2
      src/action/exists.rs
  2. 2 0
      src/cmd/handler.rs
  3. 0 1
      src/main.rs

+ 0 - 2
src/action/exists.rs

@@ -3,7 +3,6 @@ use ffsend_api::action::exists::{Error as ExistsError, Exists as ApiExists};
 use ffsend_api::file::remote_file::{FileParseError, RemoteFile};
 use ffsend_api::file::remote_file::{FileParseError, RemoteFile};
 
 
 use client::create_client;
 use client::create_client;
-#[cfg(feature = "history")]
 use cmd::matcher::main::MainMatcher;
 use cmd::matcher::main::MainMatcher;
 use cmd::matcher::{exists::ExistsMatcher, Matcher};
 use cmd::matcher::{exists::ExistsMatcher, Matcher};
 use error::ActionError;
 use error::ActionError;
@@ -26,7 +25,6 @@ impl<'a> Exists<'a> {
     pub fn invoke(&self) -> Result<(), ActionError> {
     pub fn invoke(&self) -> Result<(), ActionError> {
         // Create the command matchers
         // Create the command matchers
         let matcher_exists = ExistsMatcher::with(self.cmd_matches).unwrap();
         let matcher_exists = ExistsMatcher::with(self.cmd_matches).unwrap();
-        #[cfg(feature = "history")]
         let matcher_main = MainMatcher::with(self.cmd_matches).unwrap();
         let matcher_main = MainMatcher::with(self.cmd_matches).unwrap();
 
 
         // Get the share URL
         // Get the share URL

+ 2 - 0
src/cmd/handler.rs

@@ -21,7 +21,9 @@ use util::app_history_file_path_string;
 lazy_static! {
 lazy_static! {
     /// The default history file
     /// The default history file
     static ref DEFAULT_HISTORY_FILE: String = app_history_file_path_string();
     static ref DEFAULT_HISTORY_FILE: String = app_history_file_path_string();
+}
 
 
+lazy_static! {
     /// The default client timeout in seconds as a string
     /// The default client timeout in seconds as a string
     static ref DEFAULT_TIMEOUT: String = format!("{}", CLIENT_TIMEOUT);
     static ref DEFAULT_TIMEOUT: String = format!("{}", CLIENT_TIMEOUT);
 
 

+ 0 - 1
src/main.rs

@@ -7,7 +7,6 @@ extern crate derive_builder;
 #[macro_use]
 #[macro_use]
 extern crate failure;
 extern crate failure;
 extern crate ffsend_api;
 extern crate ffsend_api;
-#[cfg(feature = "history")]
 #[macro_use]
 #[macro_use]
 extern crate lazy_static;
 extern crate lazy_static;
 extern crate openssl_probe;
 extern crate openssl_probe;