Does the logic that generates the url require any element of the template? Have you tried putting logging in your method to check what argument comes through n both cases?
This bit could have something to do with it, as instance.data is a special read-only (Well it’s supposed to be) property that holds props, overwriting it will result in undefined behaviour when accessing data after that point
The logic that generates the url depends on the reply text which I’m getting from Template.currentData(). The reply template is a child that is generated from an each block in the parent.
{{#each replies}}
{{> reply}}
{{/each}}
I do see the url being parsed correctly on the client before I pass it into the method.
I added a server-side console.log to check the argument. When the method is in onCreated, it appears that it isn’t being called because there’s no console.log of the argument that’s passed in, but the console.log inside the method’s callback on the client returns undefined.
When the method is in onRendered, there is a server-side console.log of the argument.