The line here prevents us from encrypting an empty string, even though it was possible before 2.4.0?
|
if (data === void 0 || data === null || data === "") { |
I understand the reasoning behind this (as to prevent silly errors by developers), but this actually complicates my use case of doing E2EE, as live editing forms where users may clear a form, will throw an error.
Is there anyway I could make a PR that would disable this protection or at least add an an optional parameter to disable it?
The line here prevents us from encrypting an empty string, even though it was possible before 2.4.0?
simple-crypto-js/src/SimpleCrypto.ts
Line 51 in 0ccd426
I understand the reasoning behind this (as to prevent silly errors by developers), but this actually complicates my use case of doing E2EE, as live editing forms where users may clear a form, will throw an error.
Is there anyway I could make a PR that would disable this protection or at least add an an optional parameter to disable it?