Adyen / adyen-cse-web

[DEPRECATED] Client-side encryption on JavaScript
MIT License
15 stars 39 forks source link

Compiler error with .replace method #10

Closed Justin-Golden closed 8 years ago

Justin-Golden commented 8 years ago

I have been trying to use this, but am getting a javascript compiler error. I am using the adyen.encrypt.nodom.js file, and am having a problem with the ".replace" on line 400 (line number includes the current comments). I get the error "val.replace is not a function".

I tried replacing val = val.replace( /\D/g, '' ); with val = ("" + val).replace( /\D/g, '' ); and doing this in one other spot, but then the end result of the encrypted data always seems to be "false". Where am I going wrong?

ArnoudAdyen commented 8 years ago

H iJustin,

What is the data you are trying to get encrypted?

Regards,

Arnoud

ArnoudAdyen commented 8 years ago

Closing issue because no follow up.