about summary refs log tree commit diff
path: root/src/main.rs
diff options
context:
space:
mode:
authorVika <vika@fireburn.ru>2025-01-01 05:42:45 +0300
committerVika <vika@fireburn.ru>2025-01-01 07:08:33 +0300
commit5ad8443c8d6d9ed3f9d28ac52af529ceb41d741f (patch)
tree5d6dd326abd9cd135652e68fc893c2a95486a798 /src/main.rs
parentdf509eadc9aecef605194b7c97c5fb02bf928b79 (diff)
downloadkittybox-5ad8443c8d6d9ed3f9d28ac52af529ceb41d741f.tar.zst
Get rid of base64 and hex in favor of data_encoding crate
Less dependency duplication = more fun

Change-Id: Icbd0497a68fdd5bea3757e3c62c80008b87bce96
Diffstat (limited to 'src/main.rs')
-rw-r--r--src/main.rs3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/main.rs b/src/main.rs
index 3aee6c3..f57b0be 100644
--- a/src/main.rs
+++ b/src/main.rs
@@ -1,4 +1,3 @@
-use base64::Engine;
 use kittybox::{database::Storage, indieauth::backend::AuthBackend, media::storage::MediaStore, webmentions::Webmention, compose_kittybox};
 use tokio::{sync::Mutex, task::JoinSet};
 use std::{env, future::IntoFuture, sync::Arc};
@@ -82,7 +81,7 @@ async fn main() {
     // TODO: load from environment
     let cookie_key = axum_extra::extract::cookie::Key::from(&env::var("COOKIE_KEY")
         .as_deref()
-        .map(|s| base64::prelude::BASE64_STANDARD.decode(s.as_bytes())
+        .map(|s| data_encoding::BASE64_MIME_PERMISSIVE.decode(s.as_bytes())
             .expect("Invalid cookie key: must be base64 encoded")
         )
         .unwrap()