public IEnumerable <LibraryModel> GetAllExistingLibraries(string tenantWebUrl, string userId)
        {
            //get list of libraries from the database; permission checking will be done when
            //the user attempts to connect, not here.
            var libraries = new List <Library>();
            var user      = _loginSettingsService.GetUserById(new Guid(userId));

            if (user != null)
            {
                libraries = user.Tenant.Libraries;
            }

            return(libraries.Select(library => new LibraryModel(library)));
        }