예제 #1
0
        public RegStatus UserIsConnected(Guid userId, int tenantId)
        {
            if (CachedTelegramDao.GetUser(userId, tenantId) != null)
            {
                return(RegStatus.Registered);
            }

            return(IsAwaitingRegistration(userId, tenantId) ? RegStatus.AwaitingConfirmation : RegStatus.NotRegistered);
        }
예제 #2
0
 public UserCommands(IOptionsSnapshot <CachedTelegramDao> cachedTelegramDao)
 {
     CachedTelegramDao = cachedTelegramDao.Value;
 }
예제 #3
0
 public void Disconnect(Guid userId, int tenantId)
 {
     CachedTelegramDao.Delete(userId, tenantId);
 }