summaryrefslogtreecommitdiffstats
path: root/app/web_hub.go
diff options
context:
space:
mode:
Diffstat (limited to 'app/web_hub.go')
-rw-r--r--app/web_hub.go4
1 files changed, 4 insertions, 0 deletions
diff --git a/app/web_hub.go b/app/web_hub.go
index 21ed341ce..b4a8a4140 100644
--- a/app/web_hub.go
+++ b/app/web_hub.go
@@ -86,6 +86,10 @@ func HubUnregister(webConn *WebConn) {
}
func Publish(message *model.WebSocketEvent) {
+ if metrics := einterfaces.GetMetricsInterface(); metrics != nil {
+ metrics.IncrementWebsocketEvent(message.Event)
+ }
+
message.DoPreComputeJson()
for _, hub := range hubs {
hub.Broadcast(message)