SocketIoFacade: Remove unused method

It's not needed for compatibility since SocketIoFacade is internal
This commit is contained in:
softworkz
2025-11-17 13:14:30 +01:00
parent 5f6e4a9e9d
commit 9e9558b837

View File

@@ -2,12 +2,10 @@
// ReSharper disable once CheckNamespace
namespace ElectronNET.API;
using System;
using System.Threading.Tasks;
using ElectronNET.API.Serialization;
using SocketIO.Serializer.SystemTextJson;
using System;
using System.Linq;
using System.Text.Json;
using System.Threading.Tasks;
using SocketIO = SocketIOClient.SocketIO;
internal class SocketIoFacade
@@ -66,20 +64,6 @@ internal class SocketIoFacade
}
}
// Keep object overload for compatibility; value will be a JsonElement boxed as object.
public void On(string eventName, Action<object> action)
{
lock (_lockObj)
{
_socket.On(eventName, response =>
{
var value = (object)response.GetValue<JsonElement>();
////Console.WriteLine($"Called Event {eventName} - data {value}");
Task.Run(() => action(value));
});
}
}
public void Once(string eventName, Action action)
{
lock (_lockObj)