making changes to the dependency implementation like those in Commit 57c481e
This commit is contained in:
@@ -298,8 +298,13 @@ func AddDependencyHandler(w http.ResponseWriter, r *http.Request) {
|
||||
}
|
||||
|
||||
depType := models.DepBlocks
|
||||
dep := &models.Dependency{
|
||||
IssueID: issue.ID,
|
||||
DependsOnID: dependsOnID,
|
||||
Type: depType,
|
||||
}
|
||||
|
||||
if err := app.Issues.AddDependency(r.Context(), issue.ID, dependsOnID, depType, "web"); err != nil {
|
||||
if err := app.Issues.AddDependency(r.Context(), dep, "web"); err != nil {
|
||||
http.Error(w, "Failed to add dependency: "+err.Error(), http.StatusInternalServerError)
|
||||
return
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user