Exemple #1
0
 /// <inheritdoc />
 public string SetProviderInfo(ChatSetupInfo info)
 {
     info.AdminList.RemoveAll(x => String.IsNullOrWhiteSpace(x));
     info.AdminChannels.RemoveAll(x => String.IsNullOrWhiteSpace(x));
     info.GameChannels.RemoveAll(x => String.IsNullOrWhiteSpace(x));
     info.DevChannels.RemoveAll(x => String.IsNullOrWhiteSpace(x));
     info.WatchdogChannels.RemoveAll(x => String.IsNullOrWhiteSpace(x));
     try
     {
         lock (ChatLock)
         {
             foreach (var ChatProvider in ChatProviders)
             {
                 if (info.Provider == ChatProvider.ProviderInfo().Provider)
                 {
                     return(ChatProvider.SetProviderInfo(info));
                 }
             }
             return("Error: Invalid provider: " + info.Provider.ToString());
         }
     }
     catch (Exception e)
     {
         return(e.ToString());
     }
 }