add memos to tutorials

This commit is contained in:
jonathanlei
2023-01-24 18:03:41 -08:00
parent 61e0902d78
commit eebbfc2d23
3 changed files with 8 additions and 3 deletions

View File

@@ -56,7 +56,7 @@ function TestNetCredentials(url, altnet_name, ws_url) {
destination: test_wallet.address,
memos: [
{
data: xrpl.convertStringToHex("xrpl.org-faucet"),
data: "xrpl.org-faucet",
},
],
}),

View File

@@ -271,10 +271,15 @@ async function call_faucet(faucet_url, destination) {
if (typeof destination != "undefined") {
body["destination"] = destination
}
body["memos"] = [
{
data: "xrpl.org-tutorials",
},
]
const response = await fetch(faucet_url, {
method: 'POST',
headers: {
"Content-Type": "application/json"
"Content-Type": "application/json; charset=utf-8"
},
body: JSON.stringify(body)
})