Check input combinations

This commit is contained in:
Namrata Jha
2021-12-14 12:34:03 +00:00
committed by GitHub
parent 248e3651e3
commit c253b9d27a
3 changed files with 42 additions and 29 deletions

View File

@@ -49,6 +49,10 @@ export function deleteVersions(input: Input): Observable<boolean> {
return throwError('No token found')
}
if (!input.checkInput()) {
return throwError('Invalid input combination')
}
if (input.numOldVersionsToDelete <= 0) {
console.log(
'Number of old versions to delete input is 0 or less, no versions will be deleted'