This is an automated email from the git hooks/post-receive script. New commit to branch bow-v2-go in repository bow. See https://gitlab.nuiton.org/chorem/bow.git commit f6f40d7947e2a1f703a0207d15a16bb92b2c5536 Author: Benjamin <poussin@codelutin.com> Date: Wed May 27 19:31:43 2020 +0200 correction dans la requete sql --- pkg/repository/bookmarkRepository.go | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/pkg/repository/bookmarkRepository.go b/pkg/repository/bookmarkRepository.go index 63e5156..6a5244d 100644 --- a/pkg/repository/bookmarkRepository.go +++ b/pkg/repository/bookmarkRepository.go @@ -48,7 +48,7 @@ func BookmarkJSON(currentUser model.BowUser, id string, uri string, tags []strin } else { mainQuery = `select * from bookmark where tags @> string_to_array($1, ',')` } - + tagsJoined := strings.Join(tags, ",") q := &query{sql: fmt.Sprintf(`WITH __query AS (%[5]s), @@ -62,7 +62,7 @@ func BookmarkJSON(currentUser model.BowUser, id string, uri string, tags []strin select row_to_json(v) from (select * from __infoJson, __jsonTags, __jsonResult) v; `, orderBy, orderDirection, first, maxResult, mainQuery)} result, err = q.QueryString(currentUser, tagsJoined, fulltext, uri, id) - + if err != nil { return "", utils.NewHTTPError500(err, currentUser) } @@ -74,9 +74,9 @@ func BookmarkJSON(currentUser model.BowUser, id string, uri string, tags []strin BookmarkByIDJSON retourne le bookmark au format json */ func BookmarkByIDJSON(currentUser model.BowUser, id string) (string, error) { - q := &query{sql: `select json_agg(*) as result from bookmark where id=$4)`} + q := &query{sql: `select json_agg(b.*) as result from bookmark b where id=$4)`} result, err := q.QueryString(currentUser, id) - + if err != nil { return "", utils.NewHTTPError500(err, currentUser) } -- To stop receiving notification emails like this one, please contact chorem.org SCM administrator <admin+scm@chorem.org>.