@it-enterprise/digital-signature 1.2.1 → 1.2.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/euscp/EndUserConstants.d.ts +2 -0
- package/euscp/euscp.js +2 -2
- package/package.json +1 -1
- package/readme.md +62 -8
- package/src/DigitalSignature.js +88 -124
- package/src/GlSign.js +16 -0
- package/src/Models.js +89 -2
- package/src/Utils.js +6 -2
package/src/Utils.js
CHANGED
|
@@ -213,7 +213,7 @@ export async function downloadAndSignFiles(fileUrl, signFunc) {
|
|
|
213
213
|
: { name: getFileNameFromUrl(url), val: await downloadData(url, "binary") }));
|
|
214
214
|
|
|
215
215
|
const signs = await signFunc(fileUrl);
|
|
216
|
-
return returnNamedData ? signs : signs.map(sign => sign.val);
|
|
216
|
+
return returnNamedData ? signs : signs.map(sign => sign.val || sign);
|
|
217
217
|
} else {
|
|
218
218
|
if (!isParamValid(fileUrl)) {
|
|
219
219
|
throw {
|
|
@@ -229,6 +229,10 @@ export async function downloadAndSignFiles(fileUrl, signFunc) {
|
|
|
229
229
|
: { name: getFileNameFromUrl(fileUrl), val: await downloadData(fileUrl, "binary") };
|
|
230
230
|
|
|
231
231
|
const sign = await signFunc(fileUrl);
|
|
232
|
-
return returnNamedData ? sign : sign.val;
|
|
232
|
+
return returnNamedData ? sign : (sign.val || sign);
|
|
233
233
|
}
|
|
234
234
|
}
|
|
235
|
+
|
|
236
|
+
export function isDefaultValue(value) {
|
|
237
|
+
return value === false || value === null || typeof value === "undefined";
|
|
238
|
+
}
|