notifications styling

This commit is contained in:
realaravinth
2021-07-14 20:09:00 +05:30
parent 558dbef712
commit 69de0aaeef
16 changed files with 102 additions and 28 deletions

View File

@@ -98,6 +98,9 @@ pub type AppData = actix_web::web::Data<Arc<crate::data::Data>>;
#[actix_web::main]
async fn main() -> std::io::Result<()> {
use api::v1;
env::set_var("RUST_LOG", "info");
pretty_env_logger::init();
info!(
"{}: {}.\nFor more information, see: {}\nBuild info:\nVersion: {} commit: {}",

View File

@@ -31,7 +31,7 @@ pub mod routes {
Sitekey {
list: "/sitekey/list",
add: "/sitekey/add",
view: "/sitekey/{key}/view",
view: "/sitekey/{key}",
}
}
}

View File

@@ -125,7 +125,7 @@ mod test {
let app = get_app!(data).await;
let url = format!("/sitekey/{}/view", &key.key);
let url = format!("/sitekey/{}/", &key.key);
let list_sitekey_resp = test::call_service(
&app,

View File

@@ -18,7 +18,7 @@ use std::env;
use std::path::Path;
use config::{Config, ConfigError, Environment, File};
use log::debug;
use log::{debug, warn};
use serde::Deserialize;
use url::Url;
@@ -138,7 +138,7 @@ impl Settings {
Ok(val) => {
s.set("server.port", val).unwrap();
}
Err(e) => println!("couldn't interpret PORT: {}", e),
Err(e) => warn!("couldn't interpret PORT: {}", e),
}
match env::var("DATABASE_URL") {
@@ -147,7 +147,7 @@ impl Settings {
let database_conf = DatabaseBuilder::extract_database_url(&url);
set_from_database_url(&mut s, &database_conf);
}
Err(e) => println!("couldn't interpret DATABASE_URL: {}", e),
Err(e) => warn!("couldn't interpret DATABASE_URL: {}", e),
}
set_database_url(&mut s);