Skip to content

Commit bb6923f

Browse files
authored
fix: never unpin (#4)
never unpin stuff from pinata
1 parent a3409e2 commit bb6923f

File tree

1 file changed

+0
-22
lines changed

1 file changed

+0
-22
lines changed

index.js

Lines changed: 0 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -24,28 +24,6 @@ const cleanupAndPin = async () => {
2424
await pinata.testAuthentication();
2525
console.log("Auth successful");
2626

27-
console.log(`Cleaning up the previous pins for ${PIN_ALIAS}`);
28-
try {
29-
const previousPins = await pinata.pinList({
30-
metadata: { name: PIN_ALIAS },
31-
status: "pinned",
32-
});
33-
if (previousPins.count) {
34-
for (let pin of previousPins.rows) {
35-
try {
36-
await pinata.unpin(pin.ipfs_pin_hash);
37-
console.log(`${pin.ipfs_pin_hash} - deleted`);
38-
} catch (e) {
39-
console.log(`Failed to unpin ${pin.ipfs_pin_hash}`);
40-
core.setFailed(e);
41-
}
42-
}
43-
}
44-
} catch (e) {
45-
console.log("Failed to get a list of existing pins");
46-
core.setFailed(e);
47-
}
48-
4927
console.log("Uploading the latest build");
5028
try {
5129
const result = await pinata.pinFromFS(BUILD_LOCATION, {

0 commit comments

Comments
 (0)