Simplify patch

This commit is contained in:
Daz DeBoer 2022-08-16 17:30:58 -06:00
parent 25e9b4d3f6
commit 8df5664474
No known key found for this signature in database
GPG key ID: DD6B9F0B06683D5D
5 changed files with 8 additions and 81 deletions

24
dist/main/index.js vendored
View file

@ -115,17 +115,6 @@ function restoreCache(paths, primaryKey, restoreKeys, options) {
core.info('Cache restored successfully');
return restoredEntry;
}
// PATCH: Error handling is done in action code, allowing us to provide better reporting
// catch (error) {
// const typedError = error;
// if (typedError.name === ValidationError.name) {
// throw error;
// }
// else {
// // Supress all non-validation cache related errors because caching should be optional
// core.warning(`Failed to restore: ${error.message}`);
// }
// }
finally {
// Try to delete the archive to save space
try {
@ -194,19 +183,6 @@ function saveCache(paths, key, options) {
core.debug(`Saving Cache (ID: ${cacheId})`);
yield cacheHttpClient.saveCache(cacheId, archivePath, options);
}
// PATCH: Error handling is done in action code, allowing us to provide better reporting
// catch (error) {
// const typedError = error;
// if (typedError.name === ValidationError.name) {
// throw error;
// }
// else if (typedError.name === ReserveCacheError.name) {
// core.info(`Failed to save: ${typedError.message}`);
// }
// else {
// core.warning(`Failed to save: ${typedError.message}`);
// }
// }
finally {
// Try to delete the archive to save space
try {

File diff suppressed because one or more lines are too long