Mercurial > hg > nginx-tests
changeset 1106:4b0b10e39a08
Tests: fixed implicitly declared njs variables after 4337ed48d6d6.
author | Sergey Kandaurov <pluknet@nginx.com> |
---|---|
date | Wed, 04 Jan 2017 14:59:18 +0300 |
parents | a073a545413d |
children | d42cc683970d |
files | js.t |
diffstat | 1 files changed, 3 insertions(+), 5 deletions(-) [+] |
line wrap: on
line diff
--- a/js.t +++ b/js.t @@ -141,8 +141,7 @@ EOF } function test_ihdr(req, res) { - var s; - s = ''; + var s = '', h; for (h in req.headers) { if (h.substr(0, 3) == 'foo') { s += req.headers[h]; @@ -156,8 +155,7 @@ EOF } function test_iarg(req, res) { - var s; - s = ''; + var s = '', a; for (a in req.args) { if (a.substr(0, 3) == 'foo') { s += req.args[a]; @@ -233,7 +231,7 @@ EOF res.headers['a'] = req.args.a; res.headers['b'] = req.args.b; - s = ''; + var s = '', h; for (h in res.headers) { s += res.headers[h]; }