Skip to content

Commit

Permalink
Fix compiler nullable errors
Browse files Browse the repository at this point in the history
  • Loading branch information
DiFFoZ committed Oct 26, 2024
1 parent 0b0aed2 commit fc83121
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion Kits/Commands/CommandKitCreate.cs
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ namespace Kits.Commands
public class CommandKitCreate : Command
{
private static readonly bool s_IsUnturned = AppDomain.CurrentDomain.GetAssemblies()
.Any(x => x.GetName().Name.Equals("OpenMod.Unturned.Module.Shared"));
.Any(x => x.GetName()!.Name!.Equals("OpenMod.Unturned.Module.Shared"));

private readonly IKitStore m_KitStore;
private readonly IStringLocalizer m_StringLocalizer;
Expand Down
2 changes: 1 addition & 1 deletion Kits/Databases/DataStoreKitDatabase.cs
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ public async Task<bool> AddKitAsync(Kit kit)
throw new ArgumentNullException(nameof(kit));
}

if (m_Data.Kits.Any(x => x.Name.Equals(kit.Name, StringComparison.OrdinalIgnoreCase)))
if (m_Data.Kits!.Any(x => x.Name.Equals(kit.Name, StringComparison.OrdinalIgnoreCase)))
{
throw new UserFriendlyException(StringLocalizer["commands:kit:exist"]);
}
Expand Down
2 changes: 1 addition & 1 deletion Kits/Extensions/UnturnedExtension.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ namespace Kits.Extensions
public static class UnturnedExtension
{
private static readonly bool s_IsUnturned = AppDomain.CurrentDomain.GetAssemblies()
.Any(x => x.GetName().Name.Equals("OpenMod.Unturned"));
.Any(x => x.GetName()!.Name!.Equals("OpenMod.Unturned"));

public static void AddClothes(IPlayerUser user, IList<KitItem> kitsItems)
{
Expand Down

0 comments on commit fc83121

Please # to comment.