-
-
Notifications
You must be signed in to change notification settings - Fork 347
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
🔥 withdraw on burn item #4811
🔥 withdraw on burn item #4811
Conversation
✅ Deploy Preview for koda-nuxt ready!
To edit notification comments on pull requests, go to your Netlify site settings. |
import { bsxParamResolver, getApiCall } from '@/utils/gallery/abstractCalls' | ||
import type { ActionConsume } from './types' | ||
|
||
export function exectConsumeTx(item: ActionConsume, api, executeTransaction) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Function exectConsumeTx
has 46 lines of code (exceeds 25 allowed). Consider refactoring.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Aight!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Am I blind or where is the burn button pleas? 🥺 |
"More actions" > "Burn" |
const arg = [ | ||
[...offerWithdrawArgs, api.tx.nft.burn(collectionId, tokenId)], | ||
] | ||
|
||
executeTransaction({ | ||
cb: cb, | ||
arg: arg, | ||
successMessage: item.successMessage, | ||
errorMessage: item.errorMessage, | ||
}) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Missing arg: bsxParamResolver(item.nftId, Interaction.CONSUME, ''),
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Missing
arg: bsxParamResolver(item.nftId, Interaction.CONSUME, ''),
same thing as api.tx.nft.burn(collectionId, tokenId)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not the same sir
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
please clarify
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
TO make it work with current impl
const cb = hasOffers.value | ||
? api.tx.utility.batchAll | ||
: getApiCall(api, item.urlPrefix, Interaction.CONSUME) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
const cb = hasOffers.value | |
? api.tx.utility.batchAll | |
: getApiCall(api, item.urlPrefix, Interaction.CONSUME) | |
const cb = api.tx.utility.batchAll |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
oops my bad I've missed it
Code Climate has analyzed commit f8a9592 and detected 1 issue on this pull request. Here's the issue category breakdown:
View more on Code Climate. |
pay 50 usd |
😍 Perfect, I’ve sent the payout 🪅 Let’s grab another issue and get rewarded! |
Smelly code :/ need some refactoring in
transactionConsume
watcherPR Type
Context
Before submitting pull request, please make sure:
Optional
/snek/gallery/659233203-2
Had issue bounty label?
Screenshot 📸
Enregistrement.de.l.ecran.2023-01-23.a.2.55.39.PM.mov