-
Notifications
You must be signed in to change notification settings - Fork 16
Open
Description
As it comes, it is not possible to consume REST API.
To solve this problem you have to make a small correction.
We have to replace:
decodeMerchantParameters(data) {
const decodedData = JSON.parse(base64url.decode(data, 'utf8'));
const res = {};
Object.keys(decodedData).forEach((param) => {
res[decodeURIComponent(param)] = decodeURIComponent(decodedData[param]);
});
return res;
}
by
decodeMerchantParameters(data) {
return this.parmsToObject(JSON.parse(base64url.decode(data, 'utf8')));
}
parmsToObject(data)
{
const res = {};
Object.keys(data).forEach((param) => {
const decode = decodeURIComponent(data[param]);
if (decode == "[object Object]")
res[decodeURIComponent(param)] = this.parmsToObject(data[param]);
else
res[decodeURIComponent(param)] = decode;
});
return res;
}
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels