From 24aa68f0909ef67c16eba007c2a39a67b2ab105c Mon Sep 17 00:00:00 2001 From: kolaente Date: Tue, 19 May 2020 17:22:10 +0200 Subject: [PATCH 1/2] Don't return all tasks when a user has no lists --- pkg/models/tasks.go | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/pkg/models/tasks.go b/pkg/models/tasks.go index 3671df1174..91007f22e6 100644 --- a/pkg/models/tasks.go +++ b/pkg/models/tasks.go @@ -163,6 +163,11 @@ func (t *Task) ReadAll(a web.Auth, search string, page int, perPage int) (result func getRawTasksForLists(lists []*List, opts *taskOptions) (tasks []*Task, resultCount int, totalItems int64, err error) { + // If the user does not have any lists, don't try to get any tasks + if len(lists) == 0 { + return nil, 0, 0, nil + } + // Set the default concatinator of filter variables to or if none was provided if opts.filterConcat == "" { opts.filterConcat = filterConcatOr From 16ed5fd982b063ff96c49677ee779b68c7578752 Mon Sep 17 00:00:00 2001 From: kolaente Date: Tue, 19 May 2020 17:27:37 +0200 Subject: [PATCH 2/2] Release preparations --- CHANGELOG.md | 6 ++++++ README.md | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index a05cfb3cfa..e232d55890 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,6 +7,12 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 All releases can be found on https://code.vikunja.io/api/releases. +## [0.13.1] - 2020-05-19 + +### Fixed + +* Don't get all tasks if a user has no lists + ## [0.13] - 2020-05-12 #### Added diff --git a/README.md b/README.md index de8cc691fb..8110734ec7 100644 --- a/README.md +++ b/README.md @@ -2,7 +2,7 @@ [![Build Status](https://drone1.kolaente.de/api/badges/vikunja/api/status.svg)](https://drone1.kolaente.de/vikunja/api) [![License: GPL v3](https://img.shields.io/badge/License-GPL%20v3-blue.svg)](LICENSE) -[![Download](https://img.shields.io/badge/download-v0.13-brightgreen.svg)](https://dl.vikunja.io) +[![Download](https://img.shields.io/badge/download-v0.13.1-brightgreen.svg)](https://dl.vikunja.io) [![Docker Pulls](https://img.shields.io/docker/pulls/vikunja/api.svg)](https://hub.docker.com/r/vikunja/api/) [![Swagger Docs](https://img.shields.io/badge/swagger-docs-brightgreen.svg)](https://try.vikunja.io/api/v1/docs) [![Go Report Card](https://goreportcard.com/badge/git.kolaente.de/vikunja/api)](https://goreportcard.com/report/git.kolaente.de/vikunja/api)