Пример #1
0
 public void Delete(Authorization auth)
 {
     if (Authorizations.Remove(auth))
     {
         auth.Invalidated -= OnAuthorizationInvalidated;
         Save();
     }
 }
Пример #2
0
        private void LastFmLoginService_UserLogout(ILastFmLoginService sender, EventArgs e)
        {
            var item = Authorizations.FirstOrDefault(s => s.ServiceName == "last.fm");

            if (item == null)
            {
                return;
            }

            Authorizations.Remove(item);
            Authorizations.Add(_lastFmLoginService.GetServiceAuthorization());
        }