Skip to content
Snippets Groups Projects
Commit 221b7a49 authored by henry's avatar henry
Browse files

fixup! Bug 40209: Implement Basic Crypto Safety

Bug 41539: Remove all whitespace from copied text before testing if it
looks like a crypto address.
parent 1340b399
1 merge request!500Remove all whitespace from copied text before testing if it looks like a crypto address.
......@@ -74,7 +74,7 @@ class CryptoSafetyChild extends JSWindowActorChild {
if (event.type == "copy" || event.type == "cut") {
this.contentWindow.navigator.clipboard.readText().then(clipText => {
const selection = clipText.trim();
const selection = clipText.replace(/\s+/g, "");
if (looksLikeCryptoAddress(selection)) {
this.sendAsyncMessage("CryptoSafety:CopiedText", {
selection,
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment