This commit is contained in:
Deepak Dahiya authored and GitHub committed 2022-03-29 22:20:22 +00:00
1 parent 0cc2510a7f
commit 3d90e2772f
2 files changed
+2 -6

No files matched your search

+1 -1
View File
@@ -49,7 +49,7 @@ function checkKey(key: string): void {
* @returns boolean return true if Actions cache service feature is available, otherwise false
*/
export function isFeatureAvailable(): boolean {
export function isFeatureAvailable(): boolean {
return !!process.env['ACTIONS_CACHE_URL']
}
+1 -5
View File
@@ -32,11 +32,7 @@ const versionSalt = '1.0'
function getCacheApiUrl(resource: string): string {
// Ideally we just use ACTIONS_CACHE_URL
const baseUrl: string = (
process.env['ACTIONS_CACHE_URL'] ||
process.env['ACTIONS_RUNTIME_URL'] ||
''
).replace('pipelines', 'artifactcache')
const baseUrl: string = process.env['ACTIONS_CACHE_URL'] || ''
if (!baseUrl) {
throw new Error('Cache Service Url not found, unable to restore cache.')
}