AngularAzureSearch.WebAPI.Hubs.AnalyticsHub.OnDisconnected C# (CSharp) Method

OnDisconnected() public method

public OnDisconnected ( bool stopCalled ) : System.Threading.Tasks.Task
stopCalled bool
return System.Threading.Tasks.Task
        public override Task OnDisconnected(bool stopCalled)
        {
            if (stopCalled)
            {
                // Stop() called on a client, connection has been shut down.
                activeUsers -= 1;

                // Clients.OthersInGroups(approvedUsersList).activeUsersUpdate(activeUsers);
                Clients.All.activeUsersUpdate(activeUsers);
            }
            else
            {
                // Server hasn't heard from client in ~ 35 seconds
                // If you use a backend service, such as Service Bus, which supports multiple
                // servers, then the user may be connected to a different server not disconnected.
            }

            return base.OnDisconnected(stopCalled);
        }