Kirby Uniform logging - how do I set a template path?

I can’t seem to get uniform to accept a template path to log the email’s content, even to the default templates it ships with… what am I doing wrong here?

if ($kirby->request()->is('POST')) {
        $form->honeypotGuard()
        	->emailAction([
            'to' => 'me@example.com',
            'from' => 'info@example.com',
        ])
        ->logAction([
            'file' => kirby()->roots()->site().'/messages.log',
            'template' => kirby()->roots()->site().'/plugins/kirby-uniform/templates/emails/table.php'
        ]);;
    }

Did you try using a template name instead of a full path?

The only thing I got to work was:

'template' => 'uniform/log-json',

which is the log-json.php file at /site/plugins/kirby-uniform/templates/log-json.php

I think the template needs to be in your template folder.

That would indeed make sense but if I drop another template in there and call it I get the same error. It’s not a dealbreaker though, just wish the documentation was a little clearer on the subject. Feel free to close this thread.

If your template is in /site/templates, you should be able to just pass

'template' => 'log-json',

But I have never really used this myself