Linting
This commit is contained in:
parent
61d72cfc5b
commit
9d20d22a0b
2
main.go
2
main.go
@ -10,6 +10,7 @@ import (
|
|||||||
)
|
)
|
||||||
|
|
||||||
const (
|
const (
|
||||||
|
// MethodPurge declaration for Varnish.
|
||||||
MethodPurge = "PURGE"
|
MethodPurge = "PURGE"
|
||||||
)
|
)
|
||||||
|
|
||||||
@ -38,6 +39,7 @@ func PurgeHandler(w http.ResponseWriter, r *http.Request) {
|
|||||||
io.WriteString(w, status)
|
io.WriteString(w, status)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// SendToVarnish send to all varnish servers define in varnishList the PURGE request.
|
||||||
func SendToVarnish(url string) string {
|
func SendToVarnish(url string) string {
|
||||||
status = "200 Purged"
|
status = "200 Purged"
|
||||||
// Take url to ban as argument.
|
// Take url to ban as argument.
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user