Comparison

util/sslconfig.lua @ 6679:96e034508978

Merge 0.10->trunk
author Matthew Wild <mwild1@gmail.com>
date Wed, 13 May 2015 17:00:27 +0100
parent 6671:2d5e2ed44c22
child 6777:5de6b93d0190
comparison
equal deleted inserted replaced
6666:42fdc8dddf04 6679:96e034508978
4 local id = function (v) return v end 4 local id = function (v) return v end
5 5
6 function handlers.options(a, k, b) 6 function handlers.options(a, k, b)
7 local o = a[k] or { }; 7 local o = a[k] or { };
8 if type(b) ~= "table" then b = { b } end 8 if type(b) ~= "table" then b = { b } end
9 for k,v in pairs(b) do 9 for key, value in pairs(b) do
10 if v == true or v == false then 10 if value == true or value == false then
11 o[k] = v; 11 o[key] = value;
12 else 12 else
13 o[v] = true; 13 o[value] = true;
14 end 14 end
15 end 15 end
16 a[k] = o; 16 a[k] = o;
17 end 17 end
18 18