mirror of
https://github.com/ppy/osu.git
synced 2025-01-28 02:43:19 +08:00
change error message based on exception message
This commit is contained in:
parent
acb181ff2b
commit
c166f1a06a
@ -277,7 +277,9 @@ namespace osu.Game.Online.Chat
|
||||
|
||||
var request = new GetUserRequest(content);
|
||||
request.Success += OpenPrivateChannel;
|
||||
request.Failure += _ => target.AddNewMessages(new ErrorMessage($"User '{content}' was not found."));
|
||||
request.Failure += e => target.AddNewMessages(
|
||||
new ErrorMessage(e.InnerException?.Message == "NotFound" ? $"User '{content}' was not found." : "Could not fetch user."));
|
||||
|
||||
api.Queue(request);
|
||||
break;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user