Skip to content
This repository was archived by the owner on Oct 23, 2022. It is now read-only.

Simplified node creation #343

Closed
wants to merge 5 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 6 additions & 7 deletions http/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ use std::num::NonZeroU16;
use std::path::PathBuf;
use structopt::StructOpt;

use ipfs::{Ipfs, IpfsOptions, IpfsTypes, UninitializedIpfs};
use ipfs::{Ipfs, IpfsOptions, IpfsTypes};
use ipfs_http::{config, v0};

#[derive(Debug, StructOpt)]
Expand Down Expand Up @@ -134,13 +134,12 @@ fn main() {
let mut rt = tokio::runtime::Runtime::new().expect("Failed to create event loop");

rt.block_on(async move {
let opts: IpfsOptions = IpfsOptions::new(home.clone(), keypair, Vec::new(), false, None);
let opts: IpfsOptions =
IpfsOptions::new(home.clone(), keypair, Vec::new(), false, None, None);

let (ipfs, task): (Ipfs<ipfs::TestTypes>, _) = UninitializedIpfs::new(opts, None)
.await
.start()
.await
.expect("Initialization failed");
let mut ipfs: Ipfs<ipfs::TestTypes> = Ipfs::new(opts);

let task = ipfs.start().await.expect("Initialization failed");

tokio::spawn(task);

Expand Down
Loading