You need at least
@@ -703,10 +703,10 @@
exports[`Without wallet defined 1`] = `
Array [
Create a Token
You need at least
diff --git a/web/cashtab/src/utils/cashMethods.js b/web/cashtab/src/utils/cashMethods.js
--- a/web/cashtab/src/utils/cashMethods.js
+++ b/web/cashtab/src/utils/cashMethods.js
@@ -567,6 +567,7 @@
airdropFlag,
airdropTokenId,
encryptedEj,
+ // optionalAliasRegistrationFlag,
) => {
// encrypted mesage is mandatory when encryptionFlag is true
// airdrop token id is mandatory when airdropFlag is true
@@ -614,6 +615,13 @@
Buffer.from(currency.opReturn.appPrefixesHex.cashtab, 'hex'), // 00746162
);
+ /*
+ if (optionalAliasRegistrationFlag) {
+ add currency.opReturn.appPrefixesHex.aliasRegistration to script
+ }
+ */
+ // the alias to be registered is the optionalOpReturnMsg
+
// add the un-encrypted message to script if supplied
if (optionalOpReturnMsg) {
script.push(Buffer.from(optionalOpReturnMsg));
@@ -781,6 +789,8 @@
) {
// add the airdrop prefix to array
resultArray[i] = currency.opReturn.appPrefixesHex.airdrop;
+ // TODO: if i === 1 and message === currency.opReturn.appPrefixesHex.aliasRegistration
+ // flag accordingly
} else {
// this is either an external message or a subsequent cashtab message loop to extract the message
resultArray[i] = message;
diff --git a/web/cashtab/src/utils/chronik.js b/web/cashtab/src/utils/chronik.js
--- a/web/cashtab/src/utils/chronik.js
+++ b/web/cashtab/src/utils/chronik.js
@@ -551,6 +551,9 @@
}
if (txType === currency.opReturn.appPrefixesHex.cashtab) {
+ // if this is an alias registration, render accordingly
+ // isAliasRegistration = true;
+
// this is a Cashtab message
try {
opReturnMessage = Buffer.from(
diff --git a/web/cashtab/src/utils/transactions.js b/web/cashtab/src/utils/transactions.js
--- a/web/cashtab/src/utils/transactions.js
+++ b/web/cashtab/src/utils/transactions.js
@@ -332,6 +332,7 @@
airdropFlag,
airdropTokenId,
optionalMockPubKeyResponse = false,
+ // optionalAliasRegistrationFlag,
) => {
try {
let txBuilder = new TransactionBuilder();
@@ -406,6 +407,7 @@
airdropFlag,
airdropTokenId,
encryptedEj,
+ // optionalAliasRegistrationFlag,
);
txBuilder.addOutput(opReturnData, 0);
}
diff --git a/web/standards/op_return-prefix-guideline.md b/web/standards/op_return-prefix-guideline.md
--- a/web/standards/op_return-prefix-guideline.md
+++ b/web/standards/op_return-prefix-guideline.md
@@ -18,6 +18,7 @@
| 00746162 | Cashtab | Bitcoin ABC | ecash:pqnqv9lt7e5vjyp0w88zf2af0l92l8rxdg2jj94l5j | https://cashtab.com/ | n/a |
| 65746162 | Cashtab Encrypted | Bitcoin ABC | ecash:pqnqv9lt7e5vjyp0w88zf2af0l92l8rxdg2jj94l5j | https://cashtab.com/ | n/a |
| 64726f70 | Airdrop | Bitcoin ABC | ecash:pqnqv9lt7e5vjyp0w88zf2af0l92l8rxdg2jj94l5j | https://cashtab.com/ | n/a |
+| 2E786563 | Namespace Alias | Bitcoin ABC | ecash:pqnqv9lt7e5vjyp0w88zf2af0l92l8rxdg2jj94l5j | https://cashtab.com/ | n/a |
---