kopia lustrzana https://github.com/browsh-org/browsh
rodzic
384688302e
commit
29132f3695
|
@ -83,6 +83,10 @@ func handleHTTPServerRequest(w http.ResponseWriter, r *http.Request) {
|
|||
return
|
||||
}
|
||||
w.Header().Set("Cache-Control", "public, max-age=600")
|
||||
if (strings.Contains(urlForBrowsh, "mail.google.com")) {
|
||||
http.Redirect(w, r, "/", 301)
|
||||
return
|
||||
}
|
||||
if strings.TrimSpace(urlForBrowsh) == "" {
|
||||
if (strings.Contains(r.Host, "text.")) {
|
||||
message = "Welcome to the Browsh plain text client.\n" +
|
||||
|
@ -91,10 +95,6 @@ func handleHTTPServerRequest(w http.ResponseWriter, r *http.Request) {
|
|||
io.WriteString(w, message)
|
||||
return
|
||||
}
|
||||
if (strings.Contains(r.Host, "mail.google.com")) {
|
||||
http.Redirect(w, r, "https://html.brow.sh", 301)
|
||||
return
|
||||
}
|
||||
urlForBrowsh = "https://www.brow.sh/html-service-welcome"
|
||||
}
|
||||
if urlForBrowsh == "robots.txt" {
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
{
|
||||
"manifest_version": 2,
|
||||
"name": "Browsh",
|
||||
"version": "1.2.1",
|
||||
"version": "1.2.2",
|
||||
|
||||
"description": "Renders the browser as realtime, interactive, TTY-compatible text",
|
||||
|
||||
|
|
Ładowanie…
Reference in New Issue