mirror of
https://github.com/lxsang/antd-web-apps
synced 2024-11-20 02:18:20 +01:00
fix
This commit is contained in:
parent
0d00d1e63a
commit
7680b00b66
@ -1,4 +1,4 @@
|
||||
// Generated by CoffeeScript 1.9.3
|
||||
// Generated by CoffeeScript 1.12.7
|
||||
(function() {
|
||||
var APIManager, BaseObject, MarkOn, WebVNC, require,
|
||||
extend = function(child, parent) { for (var key in parent) { if (hasProp.call(parent, key)) child[key] = parent[key]; } function ctor() { this.constructor = child; } ctor.prototype = parent.prototype; child.prototype = new ctor(); child.__super__ = parent.prototype; return child; },
|
||||
|
@ -83,10 +83,10 @@ function VFSController:get(...)
|
||||
local r, m = require("vfs").checkperm(vfsfile, "read")
|
||||
if r then
|
||||
local mime = std.mimeOf(m)
|
||||
local finfo = ulib.file_stat(m)
|
||||
local len = tostring(math.floor(finfo.size))
|
||||
local len1 = tostring(math.floor(finfo.size - 1))
|
||||
if mime == "audio/mpeg" then
|
||||
local finfo = ulib.file_stat(m)
|
||||
local len = tostring(math.floor(finfo.size))
|
||||
local len1 = tostring(math.floor(finfo.size - 1))
|
||||
std.status(200, "OK")
|
||||
std.custom_header("Pragma", "public")
|
||||
std.custom_header("Expires", "0")
|
||||
@ -100,11 +100,12 @@ function VFSController:get(...)
|
||||
std.custom_header("Cache-Control", "no-cache, no-store")
|
||||
std.custom_header("Connection", "Keep-Alive")
|
||||
std.custom_header("Etag", "a404b-c3f-47c3a14937c80")
|
||||
std.header_flush()
|
||||
else
|
||||
std.header(mime)
|
||||
std.status(200, "OK")
|
||||
std.custom_header("Content-Type", mime)
|
||||
std.custom_header("Content-Length", len)
|
||||
end
|
||||
|
||||
std.header_flush()
|
||||
if std.is_bin(m) then
|
||||
std.fb(m)
|
||||
else
|
||||
|
Loading…
Reference in New Issue
Block a user