1
0
Fork 0
mirror of https://github.com/documize/community.git synced 2025-07-19 21:29:42 +02:00

pin spaces and documents to sidebar

This commit is contained in:
Harvey Kandola 2016-11-21 19:27:18 -08:00
parent e0d2dd47df
commit 8cc798990a
27 changed files with 2943 additions and 1589 deletions

View file

@ -276,6 +276,14 @@ func DeleteDocument(w http.ResponseWriter, r *http.Request) {
return
}
_, err = p.DeletePinnedDocument(documentID)
if err != nil && err != sql.ErrNoRows {
log.IfErr(tx.Rollback())
writeServerError(w, method, err)
return
}
log.IfErr(tx.Commit())
writeSuccessEmptyJSON(w)