Skip to content

Commit

Permalink
Rename method
Browse files Browse the repository at this point in the history
  • Loading branch information
Sella-GH committed Jun 9, 2024
1 parent f9a27e3 commit f4849c7
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions AzzyBot-Next/Services/DiscordBotService.cs
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,7 @@ public async Task<bool> LogExceptionAsync(Exception ex, DateTime timestamp, ulon
if (!messageSent)
_logger.UnableToSendMessage("Error message was not sent");

FileOperations.DeleteTempFilePath(tempFilePath);
FileOperations.DeleteFile(tempFilePath);

return true;
}
Expand Down Expand Up @@ -218,7 +218,7 @@ public async Task<bool> LogExceptionAsync(Exception ex, DateTime timestamp, Slas
if (!messageSent)
_logger.UnableToSendMessage("Error message was not sent");

FileOperations.DeleteTempFilePath(tempFilePath);
FileOperations.DeleteFile(tempFilePath);

return true;
}
Expand Down Expand Up @@ -305,7 +305,7 @@ public async Task<bool> SendMessageAsync(ulong channelId, string? content = null

foreach (string path in filePaths)
{
FileOperations.DeleteTempFilePath(path);
FileOperations.DeleteFile(path);
}
}

Expand Down
2 changes: 1 addition & 1 deletion AzzyBot-Next/Utilities/FileOperations.cs
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ public static async Task<string> CreateTempFileAsync(string content, string? fil
return tempFilePath;
}

public static void DeleteTempFilePath(string path)
public static void DeleteFile(string path)
{
ArgumentException.ThrowIfNullOrWhiteSpace(path, nameof(path));

Expand Down

0 comments on commit f4849c7

Please sign in to comment.