Skip to content
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

🔧 getProcessMetadata (useNft) #6378

Merged

Conversation

daiagi
Copy link
Contributor

@daiagi daiagi commented Jul 3, 2023

Thank you for your contribution to the KodaDot - One Stop Shop for Polkadot NFTs.

👇 __ Let's make a quick check before the contribution.

PR Type

  • Bugfix
  • fix: rmrk explore page crash due to missing meta on an nft

@daiagi daiagi requested a review from a team as a code owner July 3, 2023 07:34
@daiagi daiagi requested review from preschian and roiLeo and removed request for a team July 3, 2023 07:34
@daiagi daiagi enabled auto-merge July 3, 2023 07:34
@netlify
Copy link

netlify bot commented Jul 3, 2023

Deploy Preview for koda-canary ready!

Name Link
🔨 Latest commit 1e4c54a
🔍 Latest deploy log https://app.netlify.com/sites/koda-canary/deploys/64a27a3f0a20da0008cf5a5b
😎 Deploy Preview https://deploy-preview-6378--koda-canary.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@reviewpad
Copy link
Contributor

reviewpad bot commented Jul 3, 2023

AI-Generated Summary: This pull request includes changes made to the 'getProcessMetadata' function in the 'useNft.ts' file. The main alteration involves the refactoring of how 'hasEmptyNftAttributes' and metadata attributes are handled within the function. Instead of directly accessing 'nft.meta.attributes', a new constant 'attr' has been introduced. This constant checks for the existence of 'nft.meta.attributes' or defaults to an empty array. Consequently, 'hasEmptyNftAttributes' and the return value of getAttributes now utilize 'attr' resulting in more concise and safe code.

@reviewpad reviewpad bot added small Pull request is small waiting-for-review labels Jul 3, 2023
@reviewpad
Copy link
Contributor

reviewpad bot commented Jul 3, 2023

Reviewpad Report

⚠️ Warnings

  • Please link an issue to the pull request

@codeclimate
Copy link

codeclimate bot commented Jul 3, 2023

Code Climate has analyzed commit 1e4c54a and detected 1 issue on this pull request.

Here's the issue category breakdown:

Category Count
Complexity 1

View more on Code Climate.

Copy link
Contributor

@roiLeo roiLeo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ code lgtm

@roiLeo roiLeo added the S-code-lgtm-✅ code review guild has reviewed this PR and it's code is approved label Jul 3, 2023
@daiagi daiagi merged commit 5414faa into main Jul 3, 2023
18 of 19 checks passed
@daiagi daiagi deleted the hotfix/-insufficent-null-check-when-getting-nft-attributes branch July 3, 2023 10:21
This was referenced Jul 5, 2023
This was referenced Jul 17, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
S-code-lgtm-✅ code review guild has reviewed this PR and it's code is approved small Pull request is small waiting-for-review
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants