From 0cc2510a7fe81b69b2243ce21d72f906113c60af Mon Sep 17 00:00:00 2001 From: Deepak Dahiya <59823596+t-dedah@users.noreply.github.com> Date: Tue, 29 Mar 2022 22:19:10 +0000 Subject: [PATCH] minor --- src/cache.ts | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/src/cache.ts b/src/cache.ts index 6847cf0..687984a 100644 --- a/src/cache.ts +++ b/src/cache.ts @@ -43,6 +43,16 @@ function checkKey(key: string): void { } } +/** + * isFeatureAvailable to check the presence of Actions cache service + * + * @returns boolean return true if Actions cache service feature is available, otherwise false + */ + + export function isFeatureAvailable(): boolean { + return !!process.env['ACTIONS_CACHE_URL'] +} + /** * Restores cache from keys *