gluon-web: remove useless serialize_json alias

This commit is contained in:
Matthias Schiffer 2018-01-18 07:49:00 +01:00
parent 01336f70ec
commit 12103d9638
No known key found for this signature in database
GPG Key ID: 16EF3F64CB201D9C
2 changed files with 2 additions and 4 deletions

View File

@ -4,6 +4,7 @@
-- Licensed to the public under the Apache License 2.0.
local fs = require "nixio.fs"
local json = require "luci.jsonc"
local tpl = require "gluon.web.template"
local util = require "gluon.web.util"
local proto = require "gluon.web.http.protocol"
@ -126,7 +127,7 @@ function dispatch(http, request)
end
if type(val) == "table" then
val = util.serialize_json(val)
val = json.stringify(val)
end
return string.format(' %s="%s"', key, util.pcdata(tostring(val)))

View File

@ -5,7 +5,6 @@
local io = require "io"
local table = require "table"
local tparser = require "gluon.web.template.parser"
local json = require "luci.jsonc"
local nixio = require "nixio"
local fs = require "nixio.fs"
@ -93,8 +92,6 @@ function uniqueid(bytes)
return nixio.bin.hexlify(rand)
end
serialize_json = json.stringify
function libpath()
return '/lib/gluon/web'
end