New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@aresrpg/aresrpg-sdk

Package Overview
Dependencies
Maintainers
0
Versions
126
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@aresrpg/aresrpg-sdk - npm Package Compare versions

Comparing version 4.4.1 to 4.4.2

2

package.json
{
"name": "@aresrpg/aresrpg-sdk",
"version": "4.4.1",
"version": "4.4.2",
"description": "General SDK to interract with AresRPG",

@@ -5,0 +5,0 @@ "type": "module",

@@ -33,3 +33,3 @@ export const ITEM_CATEGORY = {

// consumables
ORB: 'orb',
CONSUMABLE: 'consumable',

@@ -73,2 +73,2 @@ CHARACTER: 'character',

export const CONSUMABLES = [ITEM_CATEGORY.ORB]
export const CONSUMABLES = [ITEM_CATEGORY.CONSUMABLE]

@@ -37,23 +37,33 @@ import { Transaction } from '@mysten/sui/transactions'

const finalizations = []
const kiosks = new Map(
kioskOwnerCaps.map(({ isPersonal, kioskId, objectId }) => {
const get_kiosk_cap = () => {
if (isPersonal) {
const { kiosk_cap, resolve_promise } = borrow_kiosk_cap({
kiosk_client,
tx,
personal_kiosk_cap_id: tx.object(objectId),
})
finalizations.push(resolve_promise)
return kiosk_cap
}
return tx.object(objectId)
}
return [kioskId, get_kiosk_cap]
}),
)
const kiosk_cap_ref = new Map()
function get_kiosk_cap_ref(kiosk_id) {
if (!kiosk_cap_ref.has(kiosk_id)) {
kiosk_cap_ref.set(kiosk_id, kiosks.get(kiosk_id)())
}
return kiosk_cap_ref.get(kiosk_id)
}
return {
tx,
kiosks: new Map(
kioskOwnerCaps.map(({ isPersonal, kioskId, objectId }) => {
const get_kiosk_cap = () => {
if (isPersonal) {
const { kiosk_cap, resolve_promise } = borrow_kiosk_cap({
kiosk_client,
tx,
personal_kiosk_cap_id: tx.object(objectId),
})
finalizations.push(resolve_promise)
return kiosk_cap
}
return tx.object(objectId)
}
return [kioskId, get_kiosk_cap]
}),
),
get_kiosk_cap_ref,
kiosks,
finalize() {

@@ -60,0 +70,0 @@ finalizations.forEach(finalize => finalize())

@@ -14,3 +14,3 @@ import { Transaction } from '@mysten/sui/transactions'

tx.object(types.ITEM_PROTECTED_POLICY),
tx.pure.id(item_id),
typeof item_id === 'string' ? tx.pure.id(item_id) : item_id,
tx.object(types.VERSION),

@@ -17,0 +17,0 @@ ],

@@ -26,3 +26,3 @@ export namespace ITEM_CATEGORY {

let RESOURCE: string;
let ORB: string;
let CONSUMABLE: string;
let CHARACTER: string;

@@ -29,0 +29,0 @@ }

@@ -101,2 +101,3 @@ export function SDK({ rpc_url, network, }: {

tx: import("@mysten/sui/transactions").Transaction;
get_kiosk_cap_ref: (kiosk_id: any) => any;
kiosks: Map<string, () => any>;

@@ -103,0 +104,0 @@ finalize(): void;

@@ -9,2 +9,3 @@ /**

tx: Transaction;
get_kiosk_cap_ref: (kiosk_id: any) => any;
kiosks: Map<string, () => any>;

@@ -11,0 +12,0 @@ finalize(): void;

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc