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

Gscan does not detect custom setting usage inside a get helper #464

Open
truekasun opened this issue Jan 19, 2023 · 4 comments
Open

Gscan does not detect custom setting usage inside a get helper #464

truekasun opened this issue Jan 19, 2023 · 4 comments
Labels

Comments

@truekasun
Copy link

truekasun commented Jan 19, 2023

gscan result on Ghost
image

featured.hbs
image

package.json
image


Note:
The expected functionality (Tags filtered from the slugs inside the custom setting) is working fine. But it throws an error while validating.

@ErisDS ErisDS added the bug label Feb 2, 2023
@ErisDS
Copy link
Member

ErisDS commented Feb 2, 2023

Hey there, thank you so much for the detailed bug report.

That does look like something that shouldn't happen! A PR to fix this issue would be very welcome 🙂

@unitof
Copy link

unitof commented Mar 2, 2024

@truekasun Is your featured.hbs located in your theme's partials/ directory? If so, this may actually be #523, and not have anything to do with the #get helper function.

@cathysarisky
Copy link
Contributor

This is a separate bug from the partials/ problem. (Although it might have BOTH problems.) (I applied @unitof 's fix, and nope, these are still not parsed correctly.)

@cathysarisky
Copy link
Contributor

cathysarisky commented Oct 23, 2024

Adding on a bit with another example:
{{#get "posts" filter="featured:false+tags:-[{{@custom.tag_1_slug}}]" [email protected]_post_count include="tags,authors" }}

@custom.latest_post_count is OK. But @custom.tag_1_slug is not.

{{#match @custom.tag_1_slug "=" "fred"}} is also ok.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants