* Add Cloudflare R2 impl

* Bump actix version

* Fix sec issues
This commit is contained in:
Geometrically
2022-10-22 21:23:31 -07:00
committed by GitHub
parent 07edb998e4
commit 6e72be54cb
18 changed files with 265 additions and 181 deletions

View File

@@ -1,10 +1,10 @@
use std::str::FromStr;
pub fn parse_var<T: FromStr>(var: &'static str) -> Option<T> {
dotenv::var(var).ok().and_then(|i| i.parse().ok())
dotenvy::var(var).ok().and_then(|i| i.parse().ok())
}
pub fn parse_strings_from_var(var: &'static str) -> Option<Vec<String>> {
dotenv::var(var)
dotenvy::var(var)
.ok()
.and_then(|s| serde_json::from_str::<Vec<String>>(&s).ok())
}