jlegewie / zotfile

Zotero plugin to manage your attachments: automatically rename, move, and attach PDFs (or other files) to Zotero items, sync PDFs from your Zotero library to your (mobile) PDF reader (e.g. an iPad, Android tablet, etc.), and extract PDF annotations.
4.05k stars 281 forks source link

fix "year" wildcard #625

Closed qqobb closed 2 years ago

qqobb commented 2 years ago

The current default wildcard for "year" is

{
    "y": {
        "field": {
            "default": "date",
            "patent": "issueDate"
        },
        "operations": [{
            "function": "exec",
            "regex": "\\\\d{4}"
        }]
    }
}

This is no longer necessary and produces errors as reported in #624. We can now use the (virtual) "year" field instead:

{
    "y": "year"
}

This also works for "patent" items. Note that the field "issueDate" of "patent" items is now base-mapped to the "date" field, see https://api.zotero.org/schema.

Fixes #624.

jlegewie commented 2 years ago

I just published 5.1.2 with this PR. Hope that fixes the problem.