Here’s the catch: only this plugin does old-style meta files.  And in a wrong way.

1. `type` should not be here, that line should be removed for the time being (till the post type PR is pulled in).
2. `kw` is used instead of `metadata`.
3. `if onefile:` should not be there.

I am:

1. Pulling your code in.
2. Applying those three easy fixes.