Use node-red-stop to ensure it’s stopped. Then from the command line run node-red —safe to start but not run. Then you should be able to edit and fix your flow before deploying again to restart.
PS - the flows file should be in your ~/.node-red directory - along with the credentials file ...creds.json and one level of backup - as hidden files .. use ls -a to see them