You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The above example publishes the dataset with the specified identifier and performs a minor version update. If the response
509
-
is successful, the use case does not return the dataset object, but the HTTP status code `200`. Otherwise, it throws an error.
510
-
If you want to perform a major version update, you must set the `versionUpdateType` parameter to `VersionUpdateType.MAJOR`.
511
-
509
+
is successful, the use case does not return the dataset object, but the HTTP status code `200`. Otherwise, it throws an error.\
510
+
If you want to perform a major version update, you must set the `versionUpdateType` parameter to `VersionUpdateType.MAJOR`.\
511
+
Superusers can pass `VersionUpdateType.UPDATE_CURRENT` to update metadata without changing the version number. This will overwrite the latest published version and therefore will only work for a dataset that has been published at least once. \*Note that this will only work also if there were no file changes in the update.\
512
512
The `datasetId` parameter can be a string, for persistent identifiers, or a number, for numeric identifiers.
513
513
514
514
The `versionUpdateType` parameter can be a [VersionUpdateType](../src/datasets/domain/models/VersionUpdateType.ts) enum value, which can be one of the following:
Copy file name to clipboardExpand all lines: src/datasets/domain/useCases/PublishDataset.ts
+1-1Lines changed: 1 addition & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -13,7 +13,7 @@ export class PublishDataset implements UseCase<void> {
13
13
* Publishes a dataset, given its identifier and the type of version update type.
14
14
*
15
15
* @param {number | string} [datasetId] - The dataset identifier, which can be a string (for persistent identifiers), or a number (for numeric identifiers).
16
-
* @param {VersionUpdateType} versionUpdateType - Specifies the type of version update, 'major'or 'minor'.
16
+
* @param {VersionUpdateType} versionUpdateType - Specifies the type of version update, 'major', 'minor' or 'updatecurrent'
17
17
* @returns {Promise<void>} - This method does not return anything upon successful completion.
0 commit comments