Skip to content

Commit

Permalink
placate clippy
Browse files Browse the repository at this point in the history
  • Loading branch information
maxcountryman committed Nov 12, 2023
1 parent f6603b8 commit f8e0a37
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions redis-store/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -57,9 +57,9 @@ impl SessionStore for RedisStore {
type Error = RedisStoreError;

async fn save(&self, session: &Session) -> Result<(), Self::Error> {
let expire = Some(session.expiry_date())
.map(OffsetDateTime::unix_timestamp)
.map(Expiration::EXAT);
let expire = Some(Expiration::EXAT(OffsetDateTime::unix_timestamp(
session.expiry_date(),
)));

self.client
.set(
Expand Down
2 changes: 1 addition & 1 deletion tests/integration-tests.rs
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ mod mysql_store_tests {
#[cfg(all(test, feature = "axum-core", feature = "mongodb-store"))]
mod mongodb_store_tests {
use axum::Router;
use tower_sessions::{MongoDBStore, SessionManagerLayer};
use tower_sessions::{mongodb, MongoDBStore, SessionManagerLayer};

use crate::common::build_app;

Expand Down

0 comments on commit f8e0a37

Please sign in to comment.