summary refs log tree commit diff
path: root/MxApiExtensions/Classes
diff options
context:
space:
mode:
authorTheArcaneBrony <myrainbowdash949@gmail.com>2023-12-01 12:34:30 +0100
committerTheArcaneBrony <myrainbowdash949@gmail.com>2023-12-01 12:34:30 +0100
commit0b662d36de30c4bdd3d9be97d08ace8d4d7be588 (patch)
tree475e4ea94cb5179236614bf5052d3164d1f2ff3b /MxApiExtensions/Classes
parentAdd more code (diff)
downloadMxApiExtensions-0b662d36de30c4bdd3d9be97d08ace8d4d7be588.tar.xz
Reformat
Diffstat (limited to 'MxApiExtensions/Classes')
-rw-r--r--MxApiExtensions/Classes/CustomLogFormatter.cs4
-rw-r--r--MxApiExtensions/Classes/MxApiExtensionsUserConfiguration.cs4
-rw-r--r--MxApiExtensions/Classes/SyncFilter.cs4
-rw-r--r--MxApiExtensions/Classes/SyncState.cs10
4 files changed, 11 insertions, 11 deletions
diff --git a/MxApiExtensions/Classes/CustomLogFormatter.cs b/MxApiExtensions/Classes/CustomLogFormatter.cs

index 69812e5..c351c6a 100644 --- a/MxApiExtensions/Classes/CustomLogFormatter.cs +++ b/MxApiExtensions/Classes/CustomLogFormatter.cs
@@ -1,7 +1,7 @@ using Microsoft.Extensions.Logging.Abstractions; using Microsoft.Extensions.Logging.Console; -namespace MxApiExtensions.Classes; +namespace MxApiExtensions.Classes; public class CustomLogFormatter : ConsoleFormatter { public CustomLogFormatter(string name) : base(name) { } @@ -9,4 +9,4 @@ public class CustomLogFormatter : ConsoleFormatter { public override void Write<TState>(in LogEntry<TState> logEntry, IExternalScopeProvider? scopeProvider, TextWriter textWriter) { Console.WriteLine("Log message"); } -} \ No newline at end of file +} diff --git a/MxApiExtensions/Classes/MxApiExtensionsUserConfiguration.cs b/MxApiExtensions/Classes/MxApiExtensionsUserConfiguration.cs
index db83637..895c5eb 100644 --- a/MxApiExtensions/Classes/MxApiExtensionsUserConfiguration.cs +++ b/MxApiExtensions/Classes/MxApiExtensionsUserConfiguration.cs
@@ -1,7 +1,7 @@ using LibMatrix.EventTypes; using LibMatrix.Interfaces; -namespace MxApiExtensions.Classes; +namespace MxApiExtensions.Classes; [MatrixEvent(EventName = EventId)] public class MxApiExtensionsUserConfiguration : EventContent { @@ -18,4 +18,4 @@ public class MxApiExtensionsUserConfiguration : EventContent { public bool DisableVoip { get; set; } = false; public bool AutoFollowTombstones { get; set; } = false; } -} \ No newline at end of file +} diff --git a/MxApiExtensions/Classes/SyncFilter.cs b/MxApiExtensions/Classes/SyncFilter.cs
index 7f2bd08..a15cbcc 100644 --- a/MxApiExtensions/Classes/SyncFilter.cs +++ b/MxApiExtensions/Classes/SyncFilter.cs
@@ -1,7 +1,7 @@ using LibMatrix.Responses; -namespace MxApiExtensions.Classes; +namespace MxApiExtensions.Classes; public interface ISyncFilter { public Task<SyncResponse> Apply(SyncResponse syncResponse); -} \ No newline at end of file +} diff --git a/MxApiExtensions/Classes/SyncState.cs b/MxApiExtensions/Classes/SyncState.cs
index 733f26d..50aa0bd 100644 --- a/MxApiExtensions/Classes/SyncState.cs +++ b/MxApiExtensions/Classes/SyncState.cs
@@ -28,7 +28,7 @@ public class SyncState { [JsonIgnore] public AuthenticatedHomeserverGeneric Homeserver { get; set; } -#region Debug stuff + #region Debug stuff public object NextSyncResponseTaskInfo => new { NextSyncResponse?.Id, @@ -39,10 +39,10 @@ public class SyncState { Status = NextSyncResponse?.Status.GetDisplayName() }; -#endregion + #endregion public SyncResponse SendEphemeralTimelineEventInRoom(string roomId, StateEventResponse @event, SyncResponse? existingResponse = null) { - if(existingResponse is null) + if (existingResponse is null) SyncQueue.Enqueue(existingResponse = new()); existingResponse.Rooms ??= new(); existingResponse.Rooms.Join ??= new(); @@ -54,7 +54,7 @@ public class SyncState { } public SyncResponse SendStatusMessage(string text, SyncResponse? existingResponse = null) { - if(existingResponse is null) + if (existingResponse is null) SyncQueue.Enqueue(existingResponse = new()); existingResponse.Presence ??= new(); // existingResponse.Presence.Events ??= new(); @@ -73,4 +73,4 @@ public class SyncState { }); return existingResponse; } -} \ No newline at end of file +}