public void subscribe(string email, string clientID) { try { MySQLBusinessLogic bl = new MySQLBusinessLogic(); int result = bl.SubscriptionEmail(email, DateTime.Now, 1); if (result == 1) { //Subscribed Clients.Client(clientID).subscribed("1"); } else if (result == 2) { //Already registered Clients.Client(clientID).subscribed("2"); } else { Clients.Client(clientID).subscribed("0"); } } catch (Exception ex) { Clients.Client(clientID).subscribed("0"); } }