In my template I have the user id variable pulled out of the URL and then I want to search through my entries for posts where that user id is included in a custom field with a users field type as well as the default "author" field.
Here's what I've got working for the author field, and I just want to include my custom "coAuthors" field type as well...
With a url like "/author/joyce"
{% set username = craft.request.segment(2) %}
{% set author = craft.users.username(username).first() %}
{% set entries = craft.entries.section('blog').authorId(author.id) %}
That works great, but how can I also include entries where that author id is set in the coAuthors custom field?
I can't even seem to find it separately. This turns up nothing
{% set entries = craft.entries.section('blog').search('coAuthors.username:author.id') %}