mirror of
https://gitea.invidious.io/iv-org/shard-spectator.git
synced 2024-08-15 00:53:35 +00:00
Raise compilation error for string interpolation in group name
This commit is contained in:
parent
941b91fef4
commit
aabec269cb
1 changed files with 2 additions and 1 deletions
|
@ -130,9 +130,10 @@ module Spectator::DSL
|
||||||
what.resolve?.is_a?(TypeNode) %}
|
what.resolve?.is_a?(TypeNode) %}
|
||||||
{{what.symbolize}}
|
{{what.symbolize}}
|
||||||
{% elsif what.is_a?(StringLiteral) ||
|
{% elsif what.is_a?(StringLiteral) ||
|
||||||
what.is_a?(StringInterpolation) ||
|
|
||||||
what.is_a?(NilLiteral) %}
|
what.is_a?(NilLiteral) %}
|
||||||
{{what}}
|
{{what}}
|
||||||
|
{% elsif what.is_a?(StringInterpolation) %}
|
||||||
|
{% raise "String interpolation isn't supported for example group names" %}
|
||||||
{% else %}
|
{% else %}
|
||||||
{{what.stringify}}
|
{{what.stringify}}
|
||||||
{% end %}
|
{% end %}
|
||||||
|
|
Loading…
Reference in a new issue