We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 7459d2b + 4d01531 commit 0ed89a8Copy full SHA for 0ed89a8
src/rmrk1.0.0/classes/nft.ts
@@ -146,7 +146,19 @@ export class NFT {
146
separate instance as the block number is an important part of an NFT's ID.`
147
);
148
}
149
- return `RMRK::CONSUME::${VERSION}::${this.getId()}`;
+ return `${PREFIX}::${OP_TYPES.CONSUME}::${VERSION}::${this.getId()}`;
150
+ }
151
+
152
+ public emote(unicode: string): string {
153
+ if (!this.block) {
154
+ throw new Error(
155
+ `You can only emote on an existing NFT. If you just minted this, please load a new,
156
+ separate instance as the block number is an important part of an NFT's ID.`
157
+ );
158
159
+ return `${PREFIX}::${
160
+ OP_TYPES.EMOTE
161
+ }::${VERSION}::${this.getId()}::${unicode}`;
162
163
164
/**
0 commit comments