Browse Source

Added a connection event when clients connect to the server.

Yuri 4 năm trước cách đây
mục cha
commit
73529f5266
1 tập tin đã thay đổi với 2 bổ sung0 xóa
  1. 2 0
      packages/fcl-web/src/websocket/fpwebsocketserver.pp

+ 2 - 0
packages/fcl-web/src/websocket/fpwebsocketserver.pp

@@ -227,6 +227,8 @@ begin
     begin
     Connections.Add(Con);
     ConnectionHandler.HandleConnection(Con,True);
+    if Assigned(OnConnect) then
+      OnConnect(Sender, Con);
     end;
 end;