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

fix: avoid mutating _layers #1455

Merged
merged 1 commit into from
Aug 16, 2022
Merged

fix: avoid mutating _layers #1455

merged 1 commit into from
Aug 16, 2022

Conversation

pi0
Copy link
Member

@pi0 pi0 commented Aug 16, 2022

πŸ”— Linked issue

❓ Type of change

  • πŸ“– Documentation (updates to the documentation or readme)
  • 🐞 Bug fix (a non-breaking change that fixes an issue)
  • πŸ‘Œ Enhancement (improving an existing functionality like performance)
  • ✨ New feature (a non-breaking change that adds functionality)
  • ⚠️ Breaking change (fix or feature that would cause existing functionality to change)

πŸ“š Description

We introduced a fix in #1418 to reverse scan layers and regression of #1404. By calling reverse() we were mutating original _layers too causing whole layer scanning logic after content being broken.

πŸ“ Checklist

  • I have linked an issue or discussion.
  • I have updated the documentation accordingly.

@netlify
Copy link

netlify bot commented Aug 16, 2022

βœ… Deploy Preview for nuxt-content ready!

Name Link
πŸ”¨ Latest commit 890472a
πŸ” Latest deploy log https://app.netlify.com/sites/nuxt-content/deploys/62fb870e55f0a10009e1d32d
😎 Deploy Preview https://deploy-preview-1455--nuxt-content.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.

@pi0 pi0 requested a review from farnabaz August 16, 2022 12:02
@pi0
Copy link
Member Author

pi0 commented Aug 16, 2022

An alternative would be not reversing layers and instead push component dirs (we can do in another PR as currently scanning is broken).

/cc @atinux Do you remember why had to originally unshift component dirs instead of pushing?

@pi0 pi0 merged commit f592e7b into main Aug 16, 2022
@pi0 pi0 deleted the fix/layers branch August 16, 2022 12:28
@farnabaz farnabaz mentioned this pull request Sep 2, 2022
farnabaz pushed a commit that referenced this pull request Sep 7, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants