diff options
Diffstat (limited to 'modules')
-rw-r--r-- | modules/context/repo.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/modules/context/repo.go b/modules/context/repo.go index 66700a6937..3815fc8cea 100644 --- a/modules/context/repo.go +++ b/modules/context/repo.go @@ -138,8 +138,8 @@ func (r *Repository) CanUseTimetracker(issue *models.Issue, user *models.User) b } // CanCreateIssueDependencies returns whether or not a user can create dependencies. -func (r *Repository) CanCreateIssueDependencies(user *models.User) bool { - return r.Permission.CanWrite(models.UnitTypeIssues) && r.Repository.IsDependenciesEnabled() +func (r *Repository) CanCreateIssueDependencies(user *models.User, isPull bool) bool { + return r.Repository.IsDependenciesEnabled() && r.Permission.CanWriteIssuesOrPulls(isPull) } // GetCommitsCount returns cached commit count for current view |