I'm rendering a template and passing some options to it. In one of them I have this code:
main: "#{ @comp[:contentItem]
unless Regex.match?(~r/width:/, to_string @comp[:contentItem])
do "width: 165px;" end
unless Regex.match?(~r/height:/, to_string @comp[:contentItem])
do "height:65px;" end
}"
I found that only the second code inside unless executes and that if I copy the first unless and repeat it again after the second unless it works, so there seems to be a problem running the code immediately after @comp[:contentItem].
I've tried using () and other combinations with no luck.