craft-linkfield
craft-linkfield copied to clipboard
Impossible to invoke a method ("getLink") on a null variable.
In craft 4, I am getting this error when using the below code.
Impossible to invoke a method ("getLink") on a null variable.
{{ block.cta.getLink({
class: 'cta cta-light',
}) }}
The field is in a Matrix > Supertable >Matrix structure.
{{ block.cta }}
outputs the URL ok.
Thanks