aerni / statamic-advanced-seo

Comprehensive SEO addon for Statamic with flexibility in mind
https://statamic.com/addons/aerni/advanced-seo
10 stars 5 forks source link

Fix policy #120

Closed aerni closed 5 months ago

aerni commented 5 months ago

This PR closes #118. The issue was triggered when checking for the user's permissions while booting the addon's CP navigation. The SeoVariablesPolicy requires existing SeoDefaultSet to determine a user's permissions. So if you don't have any SEO sets saved to file yet, you would run into this issue. We can easily fix this by ensuring we always have a set to work with, even if it's not saved to file yet.