mirror of
https://github.com/ElectronNET/Electron.NET.git
synced 2026-07-11 11:18:46 +00:00
Fix and normalize whitespace
This commit is contained in:
@@ -16,7 +16,8 @@ namespace ElectronNET.API
|
||||
private readonly TextInfo _textInfo = new CultureInfo("en-US", false).TextInfo;
|
||||
|
||||
private Events()
|
||||
{ }
|
||||
{
|
||||
}
|
||||
|
||||
public static Events Instance
|
||||
{
|
||||
@@ -94,6 +95,5 @@ namespace ElectronNET.API
|
||||
BridgeConnector.Socket.Once(listener, action);
|
||||
await BridgeConnector.Socket.Emit(subscriber, eventName, listener).ConfigureAwait(false);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -33,10 +33,7 @@ internal class SocketIoFacade
|
||||
|
||||
public void Connect()
|
||||
{
|
||||
_socket.OnError += (sender, e) =>
|
||||
{
|
||||
Console.WriteLine($"BridgeConnector Error: {sender} {e}");
|
||||
};
|
||||
_socket.OnError += (sender, e) => { Console.WriteLine($"BridgeConnector Error: {sender} {e}"); };
|
||||
|
||||
_socket.OnConnected += (_, _) =>
|
||||
{
|
||||
@@ -57,10 +54,7 @@ internal class SocketIoFacade
|
||||
{
|
||||
lock (_lockObj)
|
||||
{
|
||||
_socket.On(eventName, _ =>
|
||||
{
|
||||
Task.Run(action);
|
||||
});
|
||||
_socket.On(eventName, _ => { Task.Run(action); });
|
||||
}
|
||||
}
|
||||
|
||||
@@ -107,10 +101,10 @@ internal class SocketIoFacade
|
||||
lock (_lockObj)
|
||||
{
|
||||
_socket.On(eventName, (socketIoResponse) =>
|
||||
{
|
||||
_socket.Off(eventName);
|
||||
Task.Run(() => action(socketIoResponse.GetValue<T>()));
|
||||
});
|
||||
{
|
||||
_socket.Off(eventName);
|
||||
Task.Run(() => action(socketIoResponse.GetValue<T>()));
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user