1
0
mirror of https://github.com/actix/actix-extras.git synced 2025-01-22 14:55:56 +01:00

Change ttl to u32 (#35)

* Change TTL to u32

* Update CHANGES.md
This commit is contained in:
Omikuji 2020-04-03 16:19:21 +09:00 committed by GitHub
parent f4bcebdecd
commit f6686c9292
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 1 deletions

View File

@ -5,6 +5,8 @@
* Added `cookie_http_only` functionality to RedisSession builder, setting this
to false allows JavaScript to access cookies. Defaults to true.
* Changed type of parameter of ttl method to u32.
## [0.9.0-alpha.1]
* Update `actix` to 0.10.0-alpha.2

View File

@ -47,7 +47,7 @@ impl RedisSession {
}
/// Set time to live in seconds for session value
pub fn ttl(mut self, ttl: u16) -> Self {
pub fn ttl(mut self, ttl: u32) -> Self {
Rc::get_mut(&mut self.0).unwrap().ttl = format!("{}", ttl);
self
}