emblem-vault-sdk 1.9.9 → 1.9.11
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/bundle.js +7 -4
- package/dist/index.js +1 -1
- package/dist/utils.js +6 -3
- package/docs/bundle.js +7 -4
- package/package.json +1 -1
- package/src/utils.ts +6 -4
package/dist/bundle.js
CHANGED
|
@@ -709477,7 +709477,7 @@ const bignumber_1 = require("@ethersproject/bignumber");
|
|
|
709477
709477
|
const utils_1 = require("./utils");
|
|
709478
709478
|
const sats_connect_1 = require("sats-connect");
|
|
709479
709479
|
const derive_1 = require("./derive");
|
|
709480
|
-
const SDK_VERSION = '1.9.
|
|
709480
|
+
const SDK_VERSION = '1.9.11';
|
|
709481
709481
|
class EmblemVaultSDK {
|
|
709482
709482
|
constructor(apiKey, baseUrl) {
|
|
709483
709483
|
this.apiKey = apiKey;
|
|
@@ -710299,14 +710299,17 @@ function generateTemplate(record) {
|
|
|
710299
710299
|
*/
|
|
710300
710300
|
allowed: (data, _this, msgCallback = null) => {
|
|
710301
710301
|
var _a;
|
|
710302
|
-
if (!data || data.length == 0) {
|
|
710302
|
+
if ((!data || data.length == 0) && recordName != "Embels") {
|
|
710303
710303
|
return false;
|
|
710304
710304
|
}
|
|
710305
710305
|
let allowed = false;
|
|
710306
710306
|
let firstAsset = data[0];
|
|
710307
|
-
let assetName = firstAsset.name ? firstAsset.name : "";
|
|
710307
|
+
let assetName = (firstAsset === null || firstAsset === void 0 ? void 0 : firstAsset.name) ? firstAsset.name : "";
|
|
710308
710308
|
let message = null;
|
|
710309
|
-
if (recordName == "
|
|
710309
|
+
if (recordName == "Embels") {
|
|
710310
|
+
allowed = true;
|
|
710311
|
+
}
|
|
710312
|
+
else if (recordName == "Cursed Ordinal") {
|
|
710310
710313
|
if (data && data.length > 0) {
|
|
710311
710314
|
let allowedCoin = firstAsset.content_type != "application/json" && firstAsset.coin == "cursedordinalsbtc";
|
|
710312
710315
|
let pieces = assetName.split(' ');
|
package/dist/index.js
CHANGED
|
@@ -36,7 +36,7 @@ const bignumber_1 = require("@ethersproject/bignumber");
|
|
|
36
36
|
const utils_1 = require("./utils");
|
|
37
37
|
const sats_connect_1 = require("sats-connect");
|
|
38
38
|
const derive_1 = require("./derive");
|
|
39
|
-
const SDK_VERSION = '1.9.
|
|
39
|
+
const SDK_VERSION = '1.9.11';
|
|
40
40
|
class EmblemVaultSDK {
|
|
41
41
|
constructor(apiKey, baseUrl) {
|
|
42
42
|
this.apiKey = apiKey;
|
package/dist/utils.js
CHANGED
|
@@ -247,14 +247,17 @@ function generateTemplate(record) {
|
|
|
247
247
|
*/
|
|
248
248
|
allowed: (data, _this, msgCallback = null) => {
|
|
249
249
|
var _a;
|
|
250
|
-
if (!data || data.length == 0) {
|
|
250
|
+
if ((!data || data.length == 0) && recordName != "Embels") {
|
|
251
251
|
return false;
|
|
252
252
|
}
|
|
253
253
|
let allowed = false;
|
|
254
254
|
let firstAsset = data[0];
|
|
255
|
-
let assetName = firstAsset.name ? firstAsset.name : "";
|
|
255
|
+
let assetName = (firstAsset === null || firstAsset === void 0 ? void 0 : firstAsset.name) ? firstAsset.name : "";
|
|
256
256
|
let message = null;
|
|
257
|
-
if (recordName == "
|
|
257
|
+
if (recordName == "Embels") {
|
|
258
|
+
allowed = true;
|
|
259
|
+
}
|
|
260
|
+
else if (recordName == "Cursed Ordinal") {
|
|
258
261
|
if (data && data.length > 0) {
|
|
259
262
|
let allowedCoin = firstAsset.content_type != "application/json" && firstAsset.coin == "cursedordinalsbtc";
|
|
260
263
|
let pieces = assetName.split(' ');
|
package/docs/bundle.js
CHANGED
|
@@ -709477,7 +709477,7 @@ const bignumber_1 = require("@ethersproject/bignumber");
|
|
|
709477
709477
|
const utils_1 = require("./utils");
|
|
709478
709478
|
const sats_connect_1 = require("sats-connect");
|
|
709479
709479
|
const derive_1 = require("./derive");
|
|
709480
|
-
const SDK_VERSION = '1.9.
|
|
709480
|
+
const SDK_VERSION = '1.9.11';
|
|
709481
709481
|
class EmblemVaultSDK {
|
|
709482
709482
|
constructor(apiKey, baseUrl) {
|
|
709483
709483
|
this.apiKey = apiKey;
|
|
@@ -710299,14 +710299,17 @@ function generateTemplate(record) {
|
|
|
710299
710299
|
*/
|
|
710300
710300
|
allowed: (data, _this, msgCallback = null) => {
|
|
710301
710301
|
var _a;
|
|
710302
|
-
if (!data || data.length == 0) {
|
|
710302
|
+
if ((!data || data.length == 0) && recordName != "Embels") {
|
|
710303
710303
|
return false;
|
|
710304
710304
|
}
|
|
710305
710305
|
let allowed = false;
|
|
710306
710306
|
let firstAsset = data[0];
|
|
710307
|
-
let assetName = firstAsset.name ? firstAsset.name : "";
|
|
710307
|
+
let assetName = (firstAsset === null || firstAsset === void 0 ? void 0 : firstAsset.name) ? firstAsset.name : "";
|
|
710308
710308
|
let message = null;
|
|
710309
|
-
if (recordName == "
|
|
710309
|
+
if (recordName == "Embels") {
|
|
710310
|
+
allowed = true;
|
|
710311
|
+
}
|
|
710312
|
+
else if (recordName == "Cursed Ordinal") {
|
|
710310
710313
|
if (data && data.length > 0) {
|
|
710311
710314
|
let allowedCoin = firstAsset.content_type != "application/json" && firstAsset.coin == "cursedordinalsbtc";
|
|
710312
710315
|
let pieces = assetName.split(' ');
|
package/package.json
CHANGED
package/src/utils.ts
CHANGED
|
@@ -232,16 +232,18 @@ export function generateTemplate(record: any) {
|
|
|
232
232
|
* @param {function} - msgCallback should be a function that takes a string message
|
|
233
233
|
*/
|
|
234
234
|
allowed: (data: any[], _this: any, msgCallback: any = null) => {
|
|
235
|
-
if (!data || data.length == 0) {
|
|
235
|
+
if ((!data || data.length == 0)&& recordName != "Embels") {
|
|
236
236
|
return false
|
|
237
237
|
}
|
|
238
238
|
|
|
239
239
|
let allowed = false
|
|
240
240
|
let firstAsset = data[0]
|
|
241
|
-
let assetName = firstAsset
|
|
241
|
+
let assetName = firstAsset?.name ? firstAsset.name : ""
|
|
242
242
|
let message = null
|
|
243
|
-
|
|
244
|
-
|
|
243
|
+
if (recordName == "Embels"){
|
|
244
|
+
allowed = true
|
|
245
|
+
}
|
|
246
|
+
else if (recordName == "Cursed Ordinal") {
|
|
245
247
|
if (data && data.length > 0) {
|
|
246
248
|
let allowedCoin = firstAsset.content_type != "application/json" && firstAsset.coin == "cursedordinalsbtc"
|
|
247
249
|
let pieces = assetName.split(' ')
|