Browse Source

fix %.gz regexp

Artem Pastukhov 9 years ago
parent
commit
489ecb2544
1 changed files with 1 additions and 1 deletions
  1. 1 1
      httpserver-static.lua

+ 1 - 1
httpserver-static.lua

@@ -7,7 +7,7 @@ local function getMimeType(ext)
    -- A few MIME types. Keep list short. If you need something that is missing, let's add it.
    local mt = {css = "text/css", gif = "image/gif", html = "text/html", ico = "image/x-icon", jpeg = "image/jpeg", jpg = "image/jpeg", js = "application/javascript", json = "application/json", png = "image/png"}
    -- add comressed flag if file ends with gz
-   if ext:find("gz$") then 
+   if ext:find("%.gz$") then
        ext = ext:sub(1, -4)
        gzip = true
    end