mirror of
https://github.com/redlib-org/redlib.git
synced 2025-06-08 23:57:46 +00:00
Make gated subreddits accessible by treating them as quarantined (#722)
* Fix gated communities being unviewable by treating them as quarantined * Show restriction reason in quarantine template * Add `gated` checks for other requests
This commit is contained in:
parent
0b39d4f059
commit
eb07a2ce7c
5 changed files with 14 additions and 14 deletions
|
@ -142,7 +142,7 @@ fn request(method: &'static Method, path: String, redirect: bool, quarantine: bo
|
|||
.header("Accept-Encoding", if method == Method::GET { "gzip" } else { "identity" })
|
||||
.header("Accept-Language", "en-US,en;q=0.5")
|
||||
.header("Connection", "keep-alive")
|
||||
.header("Cookie", if quarantine { "_options=%7B%22pref_quarantine_optin%22%3A%20true%7D" } else { "" })
|
||||
.header("Cookie", if quarantine { "_options=%7B%22pref_quarantine_optin%22%3A%20true%2C%20%22pref_gated_sr_optin%22%3A%20true%7D" } else { "" })
|
||||
.body(Body::empty());
|
||||
|
||||
async move {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue