This PR makes the path parameter to resource_update optional in order to support updating of resource extra fields.
While resource_patch ckan api allows for modifying the value of a given resource extra, it does not allow for deleting an extra that is no longer needed. (note that extras are not supported in the ckanr::resource_patch)
The current behavior only supports resource_update when a the file/url is being uploaded which may require an unnecessary download and reupload of a file just to remove a metadata field.
Todos
[X] make path an optional parameter
[x] add tests
[x] update documentation
Related Issue
Example
# update an existing resource with an extra
id <- resource_update(id$id, extras = list(foo='bar'))
# purge all extras
resource_update(id)
Description
This PR makes the
path
parameter toresource_update
optional in order to support updating of resource extra fields.While
resource_patch
ckan api allows for modifying the value of a given resource extra, it does not allow for deleting an extra that is no longer needed. (note that extras are not supported in theckanr::resource_patch
)The current behavior only supports
resource_update
when a the file/url is being uploaded which may require an unnecessary download and reupload of a file just to remove a metadata field.Todos
path
an optional parameterRelated Issue
Example