From 97d8036f2692359703ddaf10ae190eda114c5d67 Mon Sep 17 00:00:00 2001
From: jbpratt <jbpratt78@gmail.com>
Date: Thu, 21 Mar 2024 01:58:58 -0500
Subject: [PATCH] Use rm over deprecated rmdir

this was officially deprecated in v16

```
(node:23073) [DEP0147] DeprecationWarning: In future versions of
Node.js, fs.rmdir(path, { recursive: true }) will be removed. Use
fs.rm(path, { recursive: true }) instead
```

https://nodejs.org/api/deprecations.html#DEP0147

Signed-off-by: jbpratt <jbpratt78@gmail.com>
---
 src/index.ts | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/index.ts b/src/index.ts
index 654a6fa..ed15885 100644
--- a/src/index.ts
+++ b/src/index.ts
@@ -417,7 +417,7 @@ async function removeDockerPodmanImageStroage(): Promise<void> {
                 await getPodmanPath(),
                 [ ...dockerPodmanOpts, "rmi", "-a", "-f" ]
             );
-            await fs.promises.rmdir(dockerPodmanRoot, { recursive: true });
+            await fs.promises.rm(dockerPodmanRoot, { recursive: true });
         }
         catch (err) {
             core.warning(`Failed to remove podman image stroage ${dockerPodmanRoot}: ${err}`);