Exemple #1
0
        public void Dispose()
        {
            if (_usersRepository != null)
            {
                _usersRepository.Dispose();
            }
            if (_communtiesRepository != null)
            {
                _communtiesRepository.Dispose();
            }
            if (_groupsRepository != null)
            {
                _groupsRepository.Dispose();
            }
            if (_campaignsRepository != null)
            {
                _campaignsRepository.Dispose();
            }
            if (_eventsRepository != null)
            {
                _eventsRepository.Dispose();
            }
            if (_userMessageRepository != null)
            {
                _userMessageRepository.Dispose();
            }
            if (_messagesRepository != null)
            {
                _messagesRepository.Dispose();
            }
            if (_dbContext != null)
            {
                _dbContext.Dispose();
            }

            GC.SuppressFinalize(this);
        }