Open pierlon opened 4 years ago
This was changed in #16 because of #12. Is get_file_data()
not working at all now?
Oh I wasn't aware of that issue. get_file_data()
is missing the required $default_headers
argument, and so fails. get_plugin_data()
internally calls get_file_data
with default headers, which we could copy over to fix this.
@kasparsd get_file_data
is throwing a PHP fatal if WP_DEBUG
is not set because of the missing $default_headers
argument. As @pierlon mentioned we might need to copy over the default headers to fix both this and the PHP fatal issue.
This plugin should technically be deprecated. The wp-foo-bar
plugin supports everything this does and more.
Using
get_file_data
requires a default set of default headers to also be passed. The correct function to use here would beget_plugin_data
, which has those headers already set.I would assume the projects that use this template also need to have this patched.