Skip to content

Commit

Permalink
fix balance check for subscription activation
Browse files Browse the repository at this point in the history
  • Loading branch information
vol4tim committed Apr 19, 2024
1 parent d6c82f0 commit 91dc837
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/views/RwsActivate.vue
Original file line number Diff line number Diff line change
Expand Up @@ -21,13 +21,13 @@ import { useSubscription } from "@/hooks/useSubscription";
import { fromUnit } from "@/utils/tools";
import { bnToBn } from "@polkadot/util";
import { computed, onUnmounted, ref, watchEffect } from "vue";
import { useSeoMeta } from '@unhead/vue';
import { useSeoMeta } from "@unhead/vue";
export default {
setup() {
useSeoMeta({
title: 'Buy a subscription'
})
title: "Buy a subscription"
});
const price = ref(0);
const freeAuctions = ref(0);
Expand Down Expand Up @@ -65,7 +65,7 @@ export default {
const onActivate = async (setStatus) => {
if (
!balance.value ||
bnToBn(balance.value).add(bnToBn(1000000000)).lt(price.value)
bnToBn(balance.value).lt(price.value.add(bnToBn(10000000)))
) {
setStatus(
"error",
Expand Down

0 comments on commit 91dc837

Please sign in to comment.