Created
June 13, 2021 20:43
-
-
Save WietseWind/94c3892e3d4b9c2f9c1c9ae5059bf560 to your computer and use it in GitHub Desktop.
livenet.xrpl.org: ugly XUMM KYC injection
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Sample: try URL: | |
// https://livenet.xrpl.org/accounts/rwietsevLFg8XSmG3bEZzFein1g8RBqWDZ | |
window.fetch('https://xumm.app/api/v1/platform/kyc-status/' + document.querySelector('h2.classic').textContent) | |
.then(r => r.json()) | |
.then(r => r.kycApproved) | |
.then(r => { | |
if (r) { | |
var kyc = document.createElement('img') | |
kyc.width = 120 | |
kyc.src = 'https://cdn.xumm.pro/kyc-check-xumm.svg' | |
kyc.style = 'cursor: pointer; margin-top: 5px;' | |
kyc.onclick = () => { | |
window.open('https://xumm.app') | |
} | |
document.querySelector('div.box-header').appendChild(kyc) | |
} | |
}) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment