Skip to content

Commit

Permalink
Update @nimiq/core to v2.0.2, hopefully fixing transaction history qu…
Browse files Browse the repository at this point in the history
…eries
  • Loading branch information
sisou committed Nov 23, 2024
1 parent b64f97d commit 83c50f8
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 7 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
"@adapttive/vue-markdown": "^4.0.1",
"@formatjs/intl-displaynames": "^3.3.4",
"@linusborg/vue-simple-portal": "^0.1.4",
"@nimiq/core": "^2.0.1",
"@nimiq/core": "^2.0.2",
"@nimiq/electrum-client": "https://github.com/nimiq/electrum-client#build",
"@nimiq/fastspot-api": "^1.10.3",
"@nimiq/hub-api": "^1.10.0",
Expand Down
5 changes: 5 additions & 0 deletions src/components/swap/SwapNotification.vue
Original file line number Diff line number Diff line change
Expand Up @@ -384,6 +384,7 @@ export default defineComponent({
// Unreachable, as Erc20AssetHandler does not fire onUpdate
} else {
updateSwap({
// @ts-expect-error Missmatch with Nimiq.PlainTransactionDetails from fastspot-api
remoteFundingTx: tx,
});
}
Expand All @@ -404,6 +405,7 @@ export default defineComponent({
updateSwap({
state: SwapState.CREATE_OUTGOING,
stateEnteredAt: Date.now(),
// @ts-expect-error Missmatch with Nimiq.PlainTransactionDetails from fastspot-api
remoteFundingTx,
});
}
Expand Down Expand Up @@ -583,6 +585,7 @@ export default defineComponent({
activeSwap.value!.fundingSerializedTx!,
(tx) => {
updateSwap({
// @ts-expect-error Missmatch with PlainTransactionDetails from fastspot-api
fundingTx: tx as Transaction<SwapAsset.NIM | SwapAsset.BTC>,
});
currentError.value = null;
Expand All @@ -604,6 +607,7 @@ export default defineComponent({
updateSwap({
state: SwapState.AWAIT_SECRET,
stateEnteredAt: Date.now(),
// @ts-expect-error Missmatch with Nimiq.PlainTransactionDetails from fastspot-api
fundingTx: fundingTx as Transaction<SwapAsset.NIM | SwapAsset.BTC>,
});
} catch (error: any) {
Expand Down Expand Up @@ -894,6 +898,7 @@ export default defineComponent({
updateSwap({
state: SwapState.COMPLETE,
stateEnteredAt: Date.now(),
// @ts-expect-error Missmatch with Nimiq.PlainTransactionDetails from fastspot-api
settlementTx:
settlementTx as Transaction<SwapAsset.NIM | SwapAsset.BTC | SwapAsset.EUR>,
});
Expand Down
1 change: 1 addition & 0 deletions src/lib/StakingUtils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ export function getPayoutText(payoutType: 'none' | 'direct' | 'restake') {

export function getStakingTransactionMeaning(transaction: Transaction, verbose: boolean): string | null {
if (transaction.sender === STAKING_CONTRACT_ADDRESS) {
// @ts-expect-error Missmatch with Nimiq.PlainTransactionDetails from fastspot-api
switch (transaction.senderData.type) {
case 'delete-validator': {
const text = i18n.t('Delete validator') as string;
Expand Down
15 changes: 9 additions & 6 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -1473,14 +1473,22 @@
dependencies:
nanoid "^3.1.20"

"@nimiq/core@^2.0.0", "@nimiq/core@^2.0.1":
"@nimiq/core@^2.0.0":
version "2.0.1"
resolved "https://registry.yarnpkg.com/@nimiq/core/-/core-2.0.1.tgz#44d947058962c597a18e52d8e7b49c6c7492d138"
integrity sha512-4YPfuxMkWgiLrEyC/ufbWnhccTe5i31s8ROwV/SV3Qd+dgaaxrHk0BWM8YmrFMfkDOj8lakenXq/4wzzqbtJ2Q==
dependencies:
comlink "^4.4.1"
websocket "^1.0.34"

"@nimiq/core@^2.0.2":
version "2.0.2"
resolved "https://registry.yarnpkg.com/@nimiq/core/-/core-2.0.2.tgz#2ea39b8dda0965ff93f2eb0a544c69feed0c9ab3"
integrity sha512-xjJQxlf83wOVh8DTxGo+2Pi2szBEMw5eJJ9mrEcPFWE57Wov4PSsJ/KTQdbZBxztgK8QWJvhx7Hc5jEslWYzNw==
dependencies:
comlink "^4.4.1"
websocket "^1.0.34"

"@nimiq/electrum-client@https://github.com/nimiq/electrum-client#build":
version "0.2.2"
resolved "https://github.com/nimiq/electrum-client#4f706a0acb13b8e8abdf5be68cfc036eb102e3fc"
Expand Down Expand Up @@ -3678,11 +3686,6 @@ caniuse-lite@^1.0.0, caniuse-lite@^1.0.30001297, caniuse-lite@^1.0.30001646:
resolved "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001683.tgz"
integrity sha512-iqmNnThZ0n70mNwvxpEC2nBJ037ZHZUoBI5Gorh1Mw6IlEAZujEoU1tXA628iZfzm7R9FvFzxbfdgml82a3k8Q==

caniuse-lite@^1.0.30001683:
version "1.0.30001683"
resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30001683.tgz#7f026a2d5d319a9cf8915a1451173052caaadc81"
integrity sha512-iqmNnThZ0n70mNwvxpEC2nBJ037ZHZUoBI5Gorh1Mw6IlEAZujEoU1tXA628iZfzm7R9FvFzxbfdgml82a3k8Q==

case-sensitive-paths-webpack-plugin@^2.3.0:
version "2.3.0"
resolved "https://registry.yarnpkg.com/case-sensitive-paths-webpack-plugin/-/case-sensitive-paths-webpack-plugin-2.3.0.tgz#23ac613cc9a856e4f88ff8bb73bbb5e989825cf7"
Expand Down

0 comments on commit 83c50f8

Please sign in to comment.