fixup url decoding
This commit is contained in:
parent
f87f206ccf
commit
471c8cc094
1 changed files with 3 additions and 2 deletions
|
|
@ -371,8 +371,9 @@ self.kiri.copyright = exports.COPYRIGHT;
|
||||||
|
|
||||||
function parseOpt(ov) {
|
function parseOpt(ov) {
|
||||||
var opt = {}, kv, kva;
|
var opt = {}, kv, kva;
|
||||||
ov.split(',').forEach(function(el) {
|
// handle kiri legacy and proper url encoding better
|
||||||
kv = el.split(':');
|
ov.split(',').map(v => v.split('&')).flat(1).forEach(function(el) {
|
||||||
|
kv = decodeURIComponent(el).split(':');
|
||||||
if (kv.length === 2) {
|
if (kv.length === 2) {
|
||||||
kva = opt[kv[0]] = opt[kv[0]] || [];
|
kva = opt[kv[0]] = opt[kv[0]] || [];
|
||||||
kva.push(decodeURIComponent(kv[1]));
|
kva.push(decodeURIComponent(kv[1]));
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue