Split hammond_data::errors to its own file.
This commit is contained in:
parent
93027e5530
commit
078331c15f
18
hammond-data/src/errors.rs
Normal file
18
hammond-data/src/errors.rs
Normal file
@ -0,0 +1,18 @@
|
|||||||
|
use diesel::migrations::RunMigrationsError;
|
||||||
|
use diesel::result;
|
||||||
|
use rss;
|
||||||
|
use hyper;
|
||||||
|
use reqwest;
|
||||||
|
|
||||||
|
use std::io;
|
||||||
|
|
||||||
|
error_chain! {
|
||||||
|
foreign_links {
|
||||||
|
MigrationError(RunMigrationsError);
|
||||||
|
DieselResultError(result::Error);
|
||||||
|
RSSError(rss::Error);
|
||||||
|
HyperError(hyper::error::Error);
|
||||||
|
ReqError(reqwest::Error);
|
||||||
|
IoError(io::Error);
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -15,12 +15,12 @@ extern crate diesel;
|
|||||||
#[macro_use]
|
#[macro_use]
|
||||||
extern crate diesel_codegen;
|
extern crate diesel_codegen;
|
||||||
|
|
||||||
|
extern crate hyper;
|
||||||
extern crate rayon;
|
extern crate rayon;
|
||||||
extern crate reqwest;
|
extern crate reqwest;
|
||||||
extern crate hyper;
|
|
||||||
extern crate xdg;
|
|
||||||
extern crate rss;
|
|
||||||
extern crate rfc822_sanitizer;
|
extern crate rfc822_sanitizer;
|
||||||
|
extern crate rss;
|
||||||
|
extern crate xdg;
|
||||||
|
|
||||||
pub mod dbqueries;
|
pub mod dbqueries;
|
||||||
pub mod models;
|
pub mod models;
|
||||||
@ -28,27 +28,7 @@ pub mod schema;
|
|||||||
|
|
||||||
pub mod index_feed;
|
pub mod index_feed;
|
||||||
pub mod feedparser;
|
pub mod feedparser;
|
||||||
|
pub mod errors;
|
||||||
pub mod errors {
|
|
||||||
|
|
||||||
use diesel::migrations::RunMigrationsError;
|
|
||||||
use diesel::result;
|
|
||||||
use rss;
|
|
||||||
use hyper;
|
|
||||||
use reqwest;
|
|
||||||
use std::io;
|
|
||||||
|
|
||||||
error_chain! {
|
|
||||||
foreign_links {
|
|
||||||
MigrationError(RunMigrationsError);
|
|
||||||
DieselResultError(result::Error);
|
|
||||||
RSSError(rss::Error);
|
|
||||||
HyperError(hyper::error::Error);
|
|
||||||
ReqError(reqwest::Error);
|
|
||||||
IoError(io::Error);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
use errors::*;
|
use errors::*;
|
||||||
use diesel::prelude::*;
|
use diesel::prelude::*;
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user