Merge remote-tracking branch 'origin/master' into ChatManager_with_BindableCollection

This commit is contained in:
smoogipoo
2018-11-26 16:12:55 +09:00
28 changed files with 281 additions and 50 deletions

View File

@ -274,11 +274,13 @@ namespace osu.Game.Online.Chat
{
Channel found = null;
var available = AvailableChannels.FirstOrDefault(c => c.Id == lookup.Id);
bool lookupCondition(Channel ch) => lookup.Id > 0 ? ch.Id == lookup.Id : lookup.Name == ch.Name;
var available = AvailableChannels.FirstOrDefault(lookupCondition);
if (available != null)
found = available;
var joined = JoinedChannels.FirstOrDefault(c => c.Id == lookup.Id);
var joined = JoinedChannels.FirstOrDefault(lookupCondition);
if (found == null && joined != null)
found = joined;