add: CACHE_BREAKER env var
This commit is contained in:
parent
69fc3ca490
commit
aceb51c21c
7 changed files with 18 additions and 9 deletions
|
@ -495,6 +495,13 @@ pub(crate) async fn initial_context(
|
|||
}
|
||||
|
||||
ctx.insert("lang", &lang.data);
|
||||
ctx.insert("random_cache_breaker", &CACHE_BREAKER.clone());
|
||||
ctx.insert(
|
||||
"random_cache_breaker",
|
||||
&if let Ok(c) = std::env::var("CACHE_BREAKER") {
|
||||
c
|
||||
} else {
|
||||
CACHE_BREAKER.clone()
|
||||
},
|
||||
);
|
||||
ctx
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue