diff options
| author | Jokler <jokler.contact@gmail.com> | 2019-12-07 21:34:40 +0100 |
|---|---|---|
| committer | Jokler <jokler.contact@gmail.com> | 2019-12-07 21:34:40 +0100 |
| commit | f372945457078451dd62775ae2ce16a2a71f4147 (patch) | |
| tree | f4b4af2290d10efa2baed7d3ab9c52bb4052c258 /src | |
| parent | b74b1915d9c64894bb8c2d310879d0047bb87d00 (diff) | |
| download | frippy-f372945457078451dd62775ae2ce16a2a71f4147.tar.gz frippy-f372945457078451dd62775ae2ce16a2a71f4147.zip | |
Fix mysql feature by readding diesel macros
Diffstat (limited to 'src')
| -rw-r--r-- | src/lib.rs | 4 | ||||
| -rw-r--r-- | src/main.rs | 5 |
2 files changed, 8 insertions, 1 deletions
@@ -28,6 +28,10 @@ //! Frippy uses the [log](https://docs.rs/log) crate so you can log events //! which might be of interest. +#[cfg(feature = "mysql")] +#[macro_use] +extern crate diesel; + pub mod error; pub mod plugin; pub mod plugins; diff --git a/src/main.rs b/src/main.rs index 960cc3b..797d7ee 100644 --- a/src/main.rs +++ b/src/main.rs @@ -20,6 +20,10 @@ use frippy::Config; use log::{error, info}; #[cfg(feature = "mysql")] +#[macro_use] +extern crate diesel_migrations; + +#[cfg(feature = "mysql")] embed_migrations!(); fn main() { @@ -92,7 +96,6 @@ fn run() -> Result<(), Error> { { if let Some(url) = mysql_url { use diesel::MysqlConnection; - use r2d2; use r2d2_diesel::ConnectionManager; let manager = ConnectionManager::<MysqlConnection>::new(url.clone()); |
