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

bug fix in explore sort #5223

Merged
merged 4 commits into from
Mar 13, 2023
Merged

bug fix in explore sort #5223

merged 4 commits into from
Mar 13, 2023

Conversation

daiagi
Copy link
Contributor

@daiagi daiagi commented Mar 10, 2023

Thank you for your contribution to the KodaDot NFT gallery.

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

PR Type

  • Bugfix
  • Feature
  • Refactoring

Context

Before submitting pull request, please make sure:

  • My contribution builds clean without any errors or warnings
  • I've merged recent default branch -- main and I've no conflicts
  • I've tried to respect high code quality standards
  • I've didn't break any original functionality
  • I've posted a screenshot of demonstrated change in this PR

Optional

  • I've tested it at </bsx/collection>
  • I've tested PR on mobile
  • I've written unit tests 🧪
  • I've found edge cases

Had issue bounty label?

  • Fill up your KSM address: Payout

Community participation

Screenshot 📸

  • My fix has changed something on UI; a screenshot is best to understand changes for others.

@daiagi daiagi requested a review from a team as a code owner March 10, 2023 03:34
@daiagi daiagi requested review from preschian and Jarsen136 and removed request for a team March 10, 2023 03:34
@kodabot
Copy link
Collaborator

kodabot commented Mar 10, 2023

SUCCESS @daiagi PR for issue #5222 which is assigned to you. Please wait for review and don't hesitate to grab another issue in the meantime!

@netlify
Copy link

netlify bot commented Mar 10, 2023

Deploy Preview for koda-nuxt ready!

Name Link
🔨 Latest commit 60568d2
🔍 Latest deploy log https://app.netlify.com/sites/koda-nuxt/deploys/640f247191f6b700081103c8
😎 Deploy Preview https://deploy-preview-5223--koda-nuxt.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 settings.

@preschian
Copy link
Member

preschian commented Mar 10, 2023

why was this section removed anyway?

function selectiveSort(options: string[]) {
const uniqueOptions = {}
if (!Array.isArray(options)) {
return []
}
options.forEach((option) => {
const opt = option.split('_')
const identifier = opt[0]
const sort = opt[1]
uniqueOptions[identifier] = sort
})
return Object.keys(uniqueOptions).map((identifier) => {
return `${identifier}_${uniqueOptions[identifier]}`
})
}

update: I miss this section when reviewing #5158
just revert that section should be fixed right?

@daiagi
Copy link
Contributor Author

daiagi commented Mar 10, 2023

why was this section removed anyway?

function selectiveSort(options: string[]) {
const uniqueOptions = {}
if (!Array.isArray(options)) {
return []
}
options.forEach((option) => {
const opt = option.split('_')
const identifier = opt[0]
const sort = opt[1]
uniqueOptions[identifier] = sort
})
return Object.keys(uniqueOptions).map((identifier) => {
return `${identifier}_${uniqueOptions[identifier]}`
})
}

update: I miss this section when reviewing #5158 just revert that section should be fixed right?

I removed it and i shouldn't have
I just rewrote the same functionality in different code style

if you prefer, i can restore it to how it was

@preschian
Copy link
Member

if you prefer, i can restore it to how it was

I'm not a fan of the reduce function, for me, it's harder to read. but if the other ok with that, sure we can continue with it 👍

@vikiival
Copy link
Member

Agree with @preschian, the code is really hard to read.

Copy link
Member

@vikiival vikiival left a comment

Choose a reason for hiding this comment

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

.

@daiagi
Copy link
Contributor Author

daiagi commented Mar 12, 2023

OK. I'll restore it to how it was before

@codeclimate
Copy link

codeclimate bot commented Mar 13, 2023

Code Climate has analyzed commit 6dce48f and detected 0 issues on this pull request.

View more on Code Climate.

@daiagi daiagi requested a review from vikiival March 13, 2023 02:25
Copy link
Contributor

@Jarsen136 Jarsen136 left a comment

Choose a reason for hiding this comment

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

wfm

@Jarsen136 Jarsen136 added the S-works-for-me-✅ qa-guild has tested PR from end user perspective and functionality worked label Mar 13, 2023
@vikiival
Copy link
Member

pay 25 usd

@vikiival vikiival merged commit 74b0d80 into kodadot:main Mar 13, 2023
@yangwao
Copy link
Member

yangwao commented Mar 13, 2023

😍 Perfect, I’ve sent the payout
💵 $25 @ 31.96 USD/KSM ~ 0.782 $KSM
🧗 EfmnRhHaQqfT3phm4cUCHCU3gFVDoSPR1U9WXzMRQBMqZ4L
🔗 0x4c44bb5d9b53fb19b92ce99503e720c3b65a1e3bf58412ab64fedbe5e52ed75e

🪅 Let’s grab another issue and get rewarded!
🪄 github.com/kodadot/nft-gallery/issues

@yangwao yangwao added the paid pull-request has been paid label Mar 13, 2023
@vikiival vikiival mentioned this pull request Mar 15, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
paid pull-request has been paid S-visual-ok-✅ S-works-for-me-✅ qa-guild has tested PR from end user perspective and functionality worked
Projects
None yet
Development

Successfully merging this pull request may close these issues.

it is possible to select contradicting options in explore sort
7 participants