I'm a dumbass

This commit is contained in:
Elijah R 2023-12-04 12:00:59 -05:00
parent 625533a2d3
commit f91090a7b0

View file

@ -58,17 +58,17 @@ namespace CollabVMAgent
try try
{ {
File.WriteAllBytes(UploadsFolder + @"\" + msg.Filename, msg.FileData); File.WriteAllBytes(UploadsFolder + @"\" + msg.Filename, msg.FileData);
} catch (Exception e) } catch (Exception ex)
{ {
#if DEBUG #if DEBUG
Console.WriteLine($"Failed to save {msg.Filename}: {e.Message}"); Console.WriteLine($"Failed to save {msg.Filename}: {ex.Message}");
#endif #endif
return; return;
} }
#if DEBUG #if DEBUG
Console.WriteLine($"Successfully wrote {msg.Filename} ({msg.FileData.Length} bytes)"); Console.WriteLine($"Successfully wrote {msg.Filename} ({msg.FileData.Length} bytes)");
#endif #endif
Process.Start(UploadsFolder + @"\" + msg.Filename, msg.FileData); Process.Start(UploadsFolder + @"\" + msg.Filename);
break; break;
} }
} }