Moved MountPoint structure into vfs module
This commit is contained in:
parent
143e1f6761
commit
d70abba47e
4 changed files with 10 additions and 13 deletions
|
@ -5,7 +5,7 @@ use std::path;
|
|||
use toml;
|
||||
|
||||
use errors::*;
|
||||
use db::MountPoint;
|
||||
use vfs::MountPoint;
|
||||
use ddns::DDNSConfig;
|
||||
|
||||
#[derive(Deserialize)]
|
||||
|
|
|
@ -9,15 +9,15 @@ use std::path::{Path, PathBuf};
|
|||
use std::sync::{Arc, Mutex};
|
||||
|
||||
use config::UserConfig;
|
||||
use db::schema::*;
|
||||
use ddns::{DDNSConfigSource, DDNSConfig};
|
||||
use errors::*;
|
||||
use vfs::Vfs;
|
||||
use vfs::{MountPoint, Vfs};
|
||||
|
||||
mod index;
|
||||
mod models;
|
||||
mod schema;
|
||||
|
||||
pub use self::schema::*;
|
||||
pub use self::models::*;
|
||||
|
||||
#[allow(dead_code)]
|
||||
|
|
|
@ -97,16 +97,6 @@ impl NewUser {
|
|||
}
|
||||
}
|
||||
|
||||
|
||||
// VFS
|
||||
#[derive(Debug, Deserialize, Insertable, Queryable)]
|
||||
#[table_name="mount_points"]
|
||||
pub struct MountPoint {
|
||||
pub source: String,
|
||||
pub name: String,
|
||||
}
|
||||
|
||||
|
||||
// Misc Settings
|
||||
#[derive(Debug, Queryable)]
|
||||
pub struct MiscSettings {
|
||||
|
|
|
@ -2,8 +2,15 @@ use std::collections::HashMap;
|
|||
use std::path::PathBuf;
|
||||
use std::path::Path;
|
||||
|
||||
use db::mount_points;
|
||||
use errors::*;
|
||||
|
||||
#[derive(Debug, Deserialize, Insertable, Queryable)]
|
||||
#[table_name="mount_points"]
|
||||
pub struct MountPoint {
|
||||
pub source: String,
|
||||
pub name: String,
|
||||
}
|
||||
|
||||
pub struct Vfs {
|
||||
mount_points: HashMap<String, PathBuf>,
|
||||
|
|
Loading…
Add table
Reference in a new issue