add robots.txt
This commit is contained in:
@ -52,6 +52,16 @@
|
|||||||
:headers headers
|
:headers headers
|
||||||
:body data)))
|
:body data)))
|
||||||
|
|
||||||
|
|
||||||
|
(when (= path "/robots.txt")
|
||||||
|
(when (!= method "GET")
|
||||||
|
(return (error 405 "method not allowed")))
|
||||||
|
|
||||||
|
(return (dict
|
||||||
|
:code 200
|
||||||
|
:headers {"Content-Type" "text/plain"}
|
||||||
|
:body "user-agent: *\ndisallow: /\n")))
|
||||||
|
|
||||||
(when (= path "/")
|
(when (= path "/")
|
||||||
(when (!= method "GET")
|
(when (!= method "GET")
|
||||||
(return (error 405 "method not allowed")))
|
(return (error 405 "method not allowed")))
|
||||||
|
Reference in New Issue
Block a user