1
0
mirror of https://github.com/ppy/osu.git synced 2024-11-14 21:17:33 +08:00
osu-lazer/osu.Game/Overlays
Dean Herbert 603527d72d Fix potential crash when highlighting chat messages
Test failed locally in `TestPublicChannelMention`. This test seems to
specify that the same message may arrive twice with the same ID, so
rather than overthinking this one I propose we just use `FirstOrDefault`.

```csharp
TearDown : System.AggregateException : One or more errors occurred.
(Sequence contains more than one matching element)
  ----> System.InvalidOperationException : Sequence contains more than
one matching element
--TearDown
   at System.Threading.Tasks.Task.ThrowIfExceptional(Boolean
includeTaskCanceledExceptions)
   at System.Threading.Tasks.Task.Wait(Int32 millisecondsTimeout,
CancellationToken cancellationToken)
   at osu.Framework.Extensions.TaskExtensions.WaitSafely(Task task)
   at osu.Framework.Testing.TestScene.checkForErrors()
--InvalidOperationException
   at System.Linq.ThrowHelper.ThrowMoreThanOneMatchException()
   at System.Linq.Enumerable.TryGetSingle[TSource](IEnumerable`1 source,
Func`2 predicate, Boolean& found)
   at System.Linq.Enumerable.SingleOrDefault[TSource](IEnumerable`1
source, Func`2 predicate)
   at
osu.Game.Overlays.Chat.DrawableChannel.<processMessageHighlighting>b__14_0()
in
/Users/dean/Projects/osu/osu.Game/Overlays/Chat/DrawableChannel.cs:line
102
   at osu.Framework.Threading.ScheduledDelegate.RunTaskInternal()
```
2022-03-16 18:38:06 +09:00
..
AccountCreation Remove unused params from BDL methods 2022-01-15 01:06:39 +01:00
BeatmapListing Fix beatmap overlay not re-fetching results after login 2022-02-22 14:55:52 +09:00
BeatmapSet Fix scores not being recalculated in beatmap listing 2022-03-08 19:07:39 +09:00
Changelog Remove unused params from BDL methods 2022-01-15 01:06:39 +01:00
Chat Fix potential crash when highlighting chat messages 2022-03-16 18:38:06 +09:00
Comments Remove unused params from BDL methods 2022-01-15 01:06:39 +01:00
Dashboard Refactorings 2022-02-08 21:29:43 +09:00
Dialog Use LocalisableStrings where possible to leverage localisable text flow 2021-11-02 21:42:02 +01:00
Login Update further ChangeFocus usages 2022-02-15 02:42:39 +03:00
MedalSplash
Mods Better annotate initial rolling counter value set 2022-03-07 23:11:20 +01:00
Music Allow pausing game-wide audio via hotkey as long as LocalUserPlaying is not set 2022-02-24 16:00:14 +09:00
News Fix news sidebar assuming returned posts are always from given year 2022-01-19 23:13:30 +01:00
Notifications Log posted notifications 2022-01-25 23:38:48 +09:00
OSD Fix toast popups spamming samples when adjusting osu!mania scroll speed during gameplay 2021-12-15 12:45:23 +09:00
Profile Dispose cancellation token source on disposal 2022-03-04 10:01:07 +03:00
Rankings Add references to web implementation wrt property used 2022-01-09 14:46:15 +01:00
Settings Fix potential crash on rare incorrect firing of skin dropdown update methods 2022-03-09 01:08:13 +09:00
Toolbar Rename RealmContextFactory to RealmAccess 2022-01-24 20:38:07 +09:00
Volume Update one more custom transform with BorderColour type change 2022-02-14 18:52:19 +01:00
Wiki Clean up unused resolved properties 2021-12-03 18:49:49 +09:00
AccountCreationOverlay.cs Remove unused params from BDL methods 2022-01-15 01:06:39 +01:00
BeatmapListingOverlay.cs Ensure old results are cleared from beatmap overlay on logout 2022-02-22 14:56:04 +09:00
BeatmapSetOverlay.cs Clean up unused resolved properties 2021-12-03 18:49:49 +09:00
BreadcrumbControlOverlayHeader.cs Allow null for breadcrumb control 2021-07-17 20:33:26 +08:00
ChangelogOverlay.cs Remove unused params from BDL methods 2022-01-15 01:06:39 +01:00
ChatOverlay.cs Improve channel switching flow in HighlightMessage 2022-03-10 23:07:15 +03:00
DashboardOverlay.cs Implement TabbableOnlineOverlay component 2021-01-18 21:22:50 +03:00
DialogOverlay.cs Update UI cases where repeat should not be handled 2021-11-18 13:13:36 +09:00
FullscreenOverlay.cs Add localisation support to overlay header title/description 2021-04-21 14:37:29 +09:00
HoldToConfirmOverlay.cs Apply batch fixing of built-in types using var 2021-10-27 13:04:41 +09:00
INamedOverlayComponent.cs Add localisation support to overlay header title/description 2021-04-21 14:37:29 +09:00
LoginOverlay.cs Update further ChangeFocus usages 2022-02-15 02:42:39 +03:00
MedalOverlay.cs Remove redundant arguments 2021-07-05 23:52:39 +08:00
MusicController.cs Completely remove subscription from MusicController 2022-01-25 16:53:02 +09:00
NewsOverlay.cs Pass fetch more action in via ctor to avoid potential nullref 2021-05-26 22:49:39 +09:00
NotificationOverlay.cs Log posted notifications 2022-01-25 23:38:48 +09:00
NowPlayingOverlay.cs Stop detaching and exposing beatmaps from MusicController 2022-01-25 16:51:21 +09:00
OnlineOverlay.cs Hoist scroll cache declaration to original place of definition 2021-06-07 11:18:18 +02:00
OnScreenDisplay.cs Fix toast popups spamming samples when adjusting osu!mania scroll speed during gameplay 2021-12-15 12:45:23 +09:00
OverlayActivation.cs
OverlayColourProvider.cs Remove static OverlayColourProviders 2022-02-20 21:09:08 +01:00
OverlayHeader.cs Centralise fetching of overlay component titles and textures 2020-09-03 16:34:58 +09:00
OverlayHeaderBackground.cs
OverlayPanelDisplayStyleControl.cs Update mapper usages with LocalisableDescription 2021-07-31 01:47:14 +03:00
OverlayRulesetSelector.cs Revert initial ruleset value logic 2021-08-23 13:28:21 +03:00
OverlayRulesetTabItem.cs Update ruleset selector design 2020-03-24 22:14:15 +01:00
OverlayScrollContainer.cs Move action to private named method to avoid null inspection 2021-11-05 03:51:08 +03:00
OverlaySidebar.cs create abstract class OverlaySidebar 2021-06-04 00:12:13 +07:00
OverlaySortTabControl.cs fix checkbox sounds not being used for certain checkboxes 2021-06-18 21:00:08 +09:00
OverlayStreamControl.cs Adjust class naming 2020-03-04 23:08:58 +03:00
OverlayStreamItem.cs Localise friends online status stream control. 2021-06-30 21:16:21 +02:00
OverlayTabControl.cs add sound to tab controls 2021-06-18 19:16:00 +09:00
OverlayTitle.cs Add localisation support to overlay header title/description 2021-04-21 14:37:29 +09:00
OverlayView.cs Revert "Allow OverlayView fetching with no API requests required" 2020-12-18 01:27:58 +03:00
RankingsOverlay.cs Add missing null checks 2021-10-05 17:59:38 +09:00
RestoreDefaultValueButton.cs Remove doubled-up opacity specification 2021-10-18 19:43:48 +02:00
SettingsOverlay.cs Move ruleset settings to own section 2021-10-12 14:58:43 +09:00
SettingsPanel.cs Abstractify expansion logic from ExpandingButtonContainer 2022-01-23 05:41:16 +03:00
SettingsSubPanel.cs Split out expanding container logic from settings sidebar 2022-01-06 21:02:29 +09:00
SettingsToolboxGroup.cs Fix skin components toolbox not autosizing properly 2022-03-10 16:30:20 +03:00
SortDirection.cs Remove unused classes and replace overlay in game 2020-04-21 16:38:47 +09:00
TabbableOnlineOverlay.cs Add login placeholder logic to OnlineOverlay 2021-02-18 18:07:24 +09:00
TabControlOverlayHeader.cs Apply batch fixing of built-in types using var 2021-10-27 13:04:41 +09:00
UserProfileOverlay.cs Rename User to APIUser and move to correct namespace 2021-11-07 11:26:01 +09:00
VersionManager.cs Move VersionManager from osu.Desktop to osu.Game 2022-01-15 19:42:38 +01:00
VolumeOverlay.cs Let selection container handle manual selection changes 2021-07-06 13:24:18 +02:00
WaveOverlayContainer.cs Use unique samples for Dialog, NowPlaying, SettingsPanel and WaveOverlay pop-in/pop-out 2021-02-10 16:04:47 +09:00
WikiOverlay.cs Remove brackets surrounding one-line statements 2022-03-04 10:14:19 +03:00