From 55b8c129559345045e89b1e7ae8eeebbeb7aa03e Mon Sep 17 00:00:00 2001 From: ErickSkrauch Date: Fri, 16 Feb 2018 18:48:55 +0300 Subject: [PATCH] Restore Ely documentation link on the 404 page --- http/not_found.go | 1 + http/not_found_test.go | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/http/not_found.go b/http/not_found.go index 33e4705..60e88de 100644 --- a/http/not_found.go +++ b/http/not_found.go @@ -9,6 +9,7 @@ func (cfg *Config) NotFound(response http.ResponseWriter, request *http.Request) data, _ := json.Marshal(map[string]string{ "status": "404", "message": "Not Found", + "link": "http://docs.ely.by/skin-system.html", }) response.Header().Set("Content-Type", "application/json") diff --git a/http/not_found_test.go b/http/not_found_test.go index dfab394..44c8a81 100644 --- a/http/not_found_test.go +++ b/http/not_found_test.go @@ -22,6 +22,7 @@ func TestConfig_NotFound(t *testing.T) { response, _ := ioutil.ReadAll(resp.Body) assert.JSONEq(`{ "status": "404", - "message": "Not Found" + "message": "Not Found", + "link": "http://docs.ely.by/skin-system.html" }`, string(response)) }