Add: comment to clarify the DELETION

This commit is contained in:
Óscar M. Lage 2024-12-05 14:46:32 +01:00
parent dbf2cacca8
commit fad9c0fe78

View File

@ -54,6 +54,8 @@ func handleUpload(w http.ResponseWriter, r *http.Request) {
commandCounts, categories, pipeRedirectionCounts, commonPatterns := ProcessHistory(tempFile.Name()) commandCounts, categories, pipeRedirectionCounts, commonPatterns := ProcessHistory(tempFile.Name())
// THE UPLOAD FILE IS INMEDIATELY REMOVED
// ONCE THE STATS ARE GENERATED
err = os.Remove(tempFile.Name()) err = os.Remove(tempFile.Name())
if err != nil { if err != nil {
http.Error(w, "Error deleting temporary file", http.StatusInternalServerError) http.Error(w, "Error deleting temporary file", http.StatusInternalServerError)