1
0

Use db sessions for task-related things (#621)

Use db sessions for task-related things

Co-authored-by: kolaente <k@knt.li>
Reviewed-on: https://kolaente.dev/vikunja/api/pulls/621
This commit is contained in:
konrad
2020-08-01 16:54:38 +00:00
parent 0ba6ae7a18
commit e4539ef232
7 changed files with 109 additions and 45 deletions

View File

@ -36,7 +36,7 @@ func (b *Bucket) CanDelete(a web.Auth) (bool, error) {
// canDoBucket checks if the bucket exists and if the user has the right to act on it
func (b *Bucket) canDoBucket(a web.Auth) (bool, error) {
bb, err := getBucketByID(b.ID)
bb, err := getBucketByID(x.NewSession(), b.ID)
if err != nil {
return false, err
}