Skip to content

Commit

Permalink
Use exception helper
Browse files Browse the repository at this point in the history
Co-authored-by: Berkan Diler <[email protected]>
  • Loading branch information
smoogipoo and turbedi authored Jan 29, 2024
1 parent 0a0d4d5 commit 5ee40fd
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions osu.Framework/Allocation/DependencyContainer.cs
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,7 @@ public void Cache(object instance)
/// <param name="info">Extra information to identify <paramref name="instance"/> in the cache.</param>
public void Cache(object instance, CacheInfo info)
{
if (instance == null)
throw new ArgumentNullException(nameof(instance));
ArgumentNullException.ThrowIfNull(instance);

CacheAs(instance.GetType(), info, instance);
}
Expand Down

0 comments on commit 5ee40fd

Please sign in to comment.