mirror of
https://github.com/actix/actix-extras.git
synced 2024-11-27 17:22:57 +01:00
Merge pull request #33 from Dowwie/master
updated version of crate, CHANGES.md, documented cache_keygen method,…
This commit is contained in:
commit
505254f7cf
@ -1,5 +1,11 @@
|
|||||||
# Changes
|
# Changes
|
||||||
|
|
||||||
|
## 0.7 (2019-09-25)
|
||||||
|
|
||||||
|
* added cache_keygen functionality to RedisSession builder, enabling support for
|
||||||
|
customizable cache key creation
|
||||||
|
|
||||||
|
|
||||||
## 0.6.1 (2019-07-19)
|
## 0.6.1 (2019-07-19)
|
||||||
|
|
||||||
* remove ClonableService usage
|
* remove ClonableService usage
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
[package]
|
[package]
|
||||||
name = "actix-redis"
|
name = "actix-redis"
|
||||||
version = "0.6.1"
|
version = "0.7.0"
|
||||||
authors = ["Nikolay Kim <fafhrd91@gmail.com>"]
|
authors = ["Nikolay Kim <fafhrd91@gmail.com>"]
|
||||||
description = "Redis integration for actix framework"
|
description = "Redis integration for actix framework"
|
||||||
license = "MIT/Apache-2.0"
|
license = "MIT/Apache-2.0"
|
||||||
|
@ -88,6 +88,7 @@ impl RedisSession {
|
|||||||
self
|
self
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// Set a custom cache key generation strategy, expecting session key as input
|
||||||
pub fn cache_keygen(mut self, keygen: Box<dyn Fn(&str) -> String>) -> Self {
|
pub fn cache_keygen(mut self, keygen: Box<dyn Fn(&str) -> String>) -> Self {
|
||||||
Rc::get_mut(&mut self.0).unwrap().cache_keygen = keygen;
|
Rc::get_mut(&mut self.0).unwrap().cache_keygen = keygen;
|
||||||
self
|
self
|
||||||
|
Loading…
Reference in New Issue
Block a user