示例#1
0
        private Task OnDocumentsAdded(object sender, DocumentsEventArgs <T> documents)
        {
            if (!IsCacheEnabled)
            {
                return(Task.CompletedTask);
            }

            return(InvalidateCachedQueriesAsync(documents.Documents, documents.Options));
        }
示例#2
0
        private async Task OnDocumentsAdded(object sender, DocumentsEventArgs <Project> documents)
        {
            if (!IsCacheEnabled)
            {
                return;
            }

            await InvalidateCountCacheAsync(documents.Documents.Select(d => d.OrganizationId)).AnyContext();
        }
        private Task OnDocumentsAdded(object sender, DocumentsEventArgs<User> documents) {
            if (!IsCacheEnabled)
                return Task.CompletedTask;

            return InvalidateCachedQueriesAsync(documents.Documents, documents.Options);
        }