Fixed a bunch of warnings

This commit is contained in:
Andre Beging
2022-05-31 15:08:55 +02:00
parent cd22c2f215
commit 7208f1e86d
21 changed files with 202 additions and 140 deletions

View File

@@ -1,7 +1,6 @@
using Blazorise;
using FoodsharingSiegen.Contracts.Entity;
using FoodsharingSiegen.Server.Auth;
using FoodsharingSiegen.Server.Data;
using FoodsharingSiegen.Server.Data.Service;
using Microsoft.AspNetCore.Components;
@@ -20,7 +19,7 @@ namespace FoodsharingSiegen.Server.BaseClasses
/// </summary>
protected override async Task OnInitializedAsync()
{
await AuthService!.Initialize();
await AuthService.Initialize();
await base.OnInitializedAsync();
}
@@ -31,27 +30,27 @@ namespace FoodsharingSiegen.Server.BaseClasses
/// <summary>
/// Gets or sets the value of the auth service (ab)
/// </summary>
[Inject] private AuthService? AuthService { get; set; }
[Inject] protected AuthService AuthService { get; set; } = null!;
/// <summary>
/// Gets or sets the value of the audit service (ab)
/// </summary>
[Inject] private AuditService? AuditService { get; set; }
[Inject] private AuditService AuditService { get; set; } = null!;
/// <summary>
/// Gets or sets the value of the notification (ab)
/// </summary>
[Inject] protected INotificationService? Notification { get; set; }
[Inject] protected INotificationService Notification { get; set; } = null!;
/// <summary>
/// Gets or sets the value of the message (ab)
/// </summary>
[Inject] protected IMessageService? Message { get; set; }
[Inject] protected IMessageService Message { get; set; } = null!;
/// <summary>
/// Gets or sets the value of the navigation manager (ab)
/// </summary>
[Inject] protected NavigationManager? NavigationManager { get; set; }
[Inject] protected NavigationManager NavigationManager { get; set; } = null!;
#endregion