mirror of
https://github.com/documize/community.git
synced 2025-07-24 07:39:43 +02:00
[WIP] Backup process outline
This commit is contained in:
parent
8bbb0d3e82
commit
4094677792
18 changed files with 678 additions and 220 deletions
|
@ -409,6 +409,7 @@ func (h *Handler) Use(w http.ResponseWriter, r *http.Request) {
|
|||
// Clone categories.
|
||||
cats, err := h.Store.Category.GetDocumentCategoryMembership(ctx, templateID)
|
||||
if err != nil && err != sql.ErrNoRows {
|
||||
ctx.Transaction.Rollback()
|
||||
response.WriteServerError(w, method, err)
|
||||
h.Runtime.Log.Error(method, err)
|
||||
return
|
||||
|
@ -422,6 +423,7 @@ func (h *Handler) Use(w http.ResponseWriter, r *http.Request) {
|
|||
cc.SpaceID = d.SpaceID
|
||||
err = h.Store.Category.AssociateDocument(ctx, cc)
|
||||
if err != nil && err != sql.ErrNoRows {
|
||||
ctx.Transaction.Rollback()
|
||||
response.WriteServerError(w, method, err)
|
||||
h.Runtime.Log.Error(method, err)
|
||||
return
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue