diff options
| author | Andrew <saintruler@gmail.com> | 2020-11-27 17:50:54 +0400 |
|---|---|---|
| committer | Andrew <saintruler@gmail.com> | 2020-11-27 17:50:54 +0400 |
| commit | 1cc6cfef971ccb3c1d70f2a5570e445556e4f6fb (patch) | |
| tree | 4773f8178225068e19bd7418622f8dd9084543ac /Response.hs | |
| parent | fb7e450d917ec87202f9de019238b78c1b645328 (diff) | |
Changed directory structure
Diffstat (limited to 'Response.hs')
| -rw-r--r-- | Response.hs | 17 |
1 files changed, 0 insertions, 17 deletions
diff --git a/Response.hs b/Response.hs deleted file mode 100644 index be347c1..0000000 --- a/Response.hs +++ /dev/null @@ -1,17 +0,0 @@ -module Response where - -data Response - = HtmlResponse Int String -- Код возврата, содержимое HTML - | TextResponse Int String String -- Код возврата, Content-Type, содержимое HTML - deriving Show - -notFoundResponse = HtmlResponse 404 "<strong>404 Not Found</strong>" - -getStatusCode (HtmlResponse code _) = code -getStatusCode (TextResponse code _ _) = code - -getContentType (HtmlResponse _ _) = "text/html" -getContentType (TextResponse _ contentType _) = contentType - -getContent (HtmlResponse _ content) = content -getContent (TextResponse _ _ content) = content
\ No newline at end of file |