debug: detect available XCM pallet on chain

This commit is contained in:
2026-02-07 22:46:09 +03:00
parent 1caf549a71
commit 22d684c00e
3 changed files with 13 additions and 6 deletions
+1 -1
View File
@@ -1,6 +1,6 @@
{
"name": "pezkuwi-telegram-miniapp",
"version": "1.0.162",
"version": "1.0.164",
"type": "module",
"description": "Pezkuwichain Telegram Mini App - Forum, Announcements, Rewards",
"author": "Pezkuwichain Team",
+9 -2
View File
@@ -327,8 +327,15 @@ export function FundFeesModal({ isOpen, onClose }: Props) {
const weightLimit = 'Unlimited';
// Create teleport transaction - xcmPallet is used on all Pezkuwi chains
const tx = sourceApi.tx.xcmPallet.limitedTeleportAssets(
// Find which XCM pallet exists on this chain
// eslint-disable-next-line @typescript-eslint/no-explicit-any
const xcmPallet = (sourceApi.tx as any).xcmPallet || (sourceApi.tx as any).polkadotXcm;
if (!xcmPallet?.limitedTeleportAssets) {
const available = Object.keys(sourceApi.tx).filter((p) => p.toLowerCase().includes('xcm'));
throw new Error(`XCM pallet nehate dîtin. Heyî: ${available.join(', ') || 'tune'}`);
}
const tx = xcmPallet.limitedTeleportAssets(
dest,
beneficiary,
assets,
+3 -3
View File
@@ -1,5 +1,5 @@
{
"version": "1.0.162",
"buildTime": "2026-02-07T19:35:44.402Z",
"buildNumber": 1770492944403
"version": "1.0.164",
"buildTime": "2026-02-07T19:46:55.715Z",
"buildNumber": 1770493615716
}