Merge branch 'master' of https://git.cscherr.de/PlexSheep/rs-basic
cargo devel CI / cargo CI (push) Successful in 1m56s Details

This commit is contained in:
Christoph J. Scherr 2024-03-08 18:07:56 +01:00
commit ef01e4d808
Signed by: cscherrNT
GPG Key ID: 8E2B45BC51A27EA7
2 changed files with 3 additions and 3 deletions

View File

@ -1,7 +1,7 @@
use std::{convert::Infallible, fmt::Display, str::FromStr}; use std::{convert::Infallible, fmt::Display, str::FromStr};
use crate::{store::Sequence, Item, Store}; use crate::{store::Sequence, Item, Store};
use rand::{prelude::*, seq::SliceRandom}; use rand::seq::SliceRandom;
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
const ALPHABET: &str = "qwertzuiopasdfghjklyxcvbnmQWERTZUIOPASDFGHJKLYXCVBNM"; const ALPHABET: &str = "qwertzuiopasdfghjklyxcvbnmQWERTZUIOPASDFGHJKLYXCVBNM";

View File

@ -2,13 +2,13 @@ use std::{collections::HashMap, convert::Infallible, str::FromStr};
use libpt::log::{debug, error, info}; use libpt::log::{debug, error, info};
use warp::{ use warp::{
filters::{path::param, BoxedFilter}, filters::BoxedFilter,
http::StatusCode, http::StatusCode,
reject::{MissingHeader, Rejection}, reject::{MissingHeader, Rejection},
reply, Filter, Reply, reply, Filter, Reply,
}; };
use crate::{Client, Id, Item, Store, Token, StoreErr}; use crate::{Client, Id, Store, StoreErr, Token};
pub fn with_store(store: Store) -> impl Filter<Extract = (Store,), Error = Infallible> + Clone { pub fn with_store(store: Store) -> impl Filter<Extract = (Store,), Error = Infallible> + Clone {
warp::any().map(move || store.clone()) warp::any().map(move || store.clone())