Project Cannot Find File and Keeps Trying to Install

Hello! I have a project named zielobot0-1 and it has been active here for almost a year now. It is a discord bot that has the function of a leaderboard system that runs through sqlite. Because of this its storage fills up pretty quickly and in order to remove it I change directories to the ~git directory in the console and use the command rm -r to delete it’s files.

This method has worked every time I have tried it even though its very tedious, however recently when someone else who had access to this bot followed those instructions, certain files and even the server.js file managed to be deleted. I was able to restore all of the visible files however I noticed that the bot was missing crucial files in package.json and when I restored them the console returned with errors.

When Node was updated, I added the new package to the project. However this did not solve the problem and now it is saying that I am missing a certain file or directory and the project will not install the update properly. I am really stumped and even though this is an issue my bot still managed to run but it cannot install the Node update.

I would like to know if this is just an issue with my project or multiple others and if it is then was this the result of me erasing files through the ~git directory? Furthermore if there is another way to clear storage space for my bot I would like to know that as well so that something like this does not happen again.