Cleanup build warnings, ReShaper, Dictionary

This commit is contained in:
2023-07-30 17:25:04 +02:00
parent d83aa1ef5b
commit 1afa3df316
19 changed files with 84 additions and 58 deletions

View File

@ -7,9 +7,11 @@ namespace Tranga.NotificationManagers;
public class Gotify : NotificationManager
{
public string endpoint { get; }
// ReSharper disable once MemberCanBePrivate.Global
public string appToken { get; }
private readonly HttpClient _client = new();
[JsonConstructor]
public Gotify(string endpoint, string appToken, Logger? logger = null) : base(NotificationManagerType.Gotify, logger)
{
this.endpoint = endpoint;
@ -33,6 +35,7 @@ public class Gotify : NotificationManager
private class MessageData
{
// ReSharper disable four times UnusedAutoPropertyAccessor.Local
public string message { get; }
public long priority { get; }
public string title { get; }

View File

@ -6,8 +6,11 @@ namespace Tranga.NotificationManagers;
public class LunaSea : NotificationManager
{
public string id { get; }
// ReSharper disable once MemberCanBePrivate.Global
public string id { get; init; }
private readonly HttpClient _client = new();
[JsonConstructor]
public LunaSea(string id, Logger? logger = null) : base(NotificationManagerType.LunaSea, logger)
{
this.id = id;
@ -29,6 +32,7 @@ public class LunaSea : NotificationManager
private class MessageData
{
// ReSharper disable twice UnusedAutoPropertyAccessor.Local
public string title { get; }
public string body { get; }