ソースを参照

darkfid: Fix imports.

Luther Blissett 3 年 前
コミット
607be9d931
3 ファイル変更5 行追加6 行削除
  1. 3 4
      bin/darkfid/src/main.rs
  2. 1 1
      bin/darkfid/src/rpc_tx.rs
  3. 1 1
      bin/darkfid/src/rpc_wallet.rs

+ 3 - 4
bin/darkfid/src/main.rs

@@ -27,6 +27,7 @@ use darkfi::{
     net::P2pPtr,
     node::Client,
     rpc::{
+        clock_sync::check_clock,
         jsonrpc::{
             ErrorCode::{InvalidParams, MethodNotFound},
             JsonError, JsonRequest, JsonResult,
@@ -35,9 +36,7 @@ use darkfi::{
     },
     util::{
         cli::{get_log_config, get_log_level, spawn_config},
-        expand_path,
-        path::get_config_path,
-        time::check_clock,
+        path::{expand_path, get_config_path},
     },
     wallet::walletdb::init_wallet,
     Error, Result,
@@ -269,7 +268,7 @@ async fn realmain(args: Args, ex: Arc<Executor<'_>>) -> Result<()> {
         }
         // We verify that the system clock is valid before initializing
         let peers = [&args.consensus_peer_rpc[..], &args.consensus_seed_rpc[..]].concat();
-        if (check_clock(peers).await).is_err() {
+        if (check_clock(&peers).await).is_err() {
             error!("System clock is invalid, terminating...");
             return Err(Error::InvalidClock)
         };

+ 1 - 1
bin/darkfid/src/rpc_tx.rs

@@ -8,8 +8,8 @@ use darkfi::{
     crypto::{address::Address, keypair::PublicKey, token_id},
     node::MemoryState,
     rpc::jsonrpc::{ErrorCode::InvalidParams, JsonError, JsonResponse, JsonResult},
+    serial::{deserialize, serialize},
     tx::Transaction,
-    util::serial::{deserialize, serialize},
 };
 
 use super::Darkfid;

+ 1 - 1
bin/darkfid/src/rpc_wallet.rs

@@ -15,7 +15,7 @@ use darkfi::{
         ErrorCode::{InternalError, InvalidParams, ParseError},
         JsonError, JsonResponse, JsonResult,
     },
-    util::serial::{deserialize, serialize},
+    serial::{deserialize, serialize},
 };
 
 use super::Darkfid;