mirror of
https://github.com/gitbucket/gitbucket.git
synced 2025-11-06 05:25:50 +01:00
Correct activity message of reopening pull request (#2420)
* Correct activity message of reopening pull request * Fix docs
This commit is contained in:
@@ -55,7 +55,7 @@ Support
|
|||||||
- If you can't find same question and report, send it to [gitter room](https://gitter.im/gitbucket/gitbucket) before raising an issue.
|
- If you can't find same question and report, send it to [gitter room](https://gitter.im/gitbucket/gitbucket) before raising an issue.
|
||||||
- The highest priority of GitBucket is the ease of installation and API compatibility with GitHub, so your feature request might be rejected if they go against those principles.
|
- The highest priority of GitBucket is the ease of installation and API compatibility with GitHub, so your feature request might be rejected if they go against those principles.
|
||||||
|
|
||||||
What's New in 4.32.x
|
What's New in 4.33.x
|
||||||
-------------
|
-------------
|
||||||
### 4.33.0 - 31 Dec 2019
|
### 4.33.0 - 31 Dec 2019
|
||||||
|
|
||||||
|
|||||||
@@ -131,6 +131,23 @@ trait ActivityService {
|
|||||||
currentDate
|
currentDate
|
||||||
)
|
)
|
||||||
|
|
||||||
|
def recordReopenPullRequestActivity(
|
||||||
|
userName: String,
|
||||||
|
repositoryName: String,
|
||||||
|
activityUserName: String,
|
||||||
|
issueId: Int,
|
||||||
|
title: String
|
||||||
|
)(implicit s: Session): Unit =
|
||||||
|
Activities insert Activity(
|
||||||
|
userName,
|
||||||
|
repositoryName,
|
||||||
|
activityUserName,
|
||||||
|
"reopen_issue",
|
||||||
|
s"[user:${activityUserName}] reopened pull request [issue:${userName}/${repositoryName}#${issueId}]",
|
||||||
|
Some(title),
|
||||||
|
currentDate
|
||||||
|
)
|
||||||
|
|
||||||
def recordCommentIssueActivity(
|
def recordCommentIssueActivity(
|
||||||
userName: String,
|
userName: String,
|
||||||
repositoryName: String,
|
repositoryName: String,
|
||||||
|
|||||||
@@ -39,7 +39,10 @@ trait HandleCommentService {
|
|||||||
))
|
))
|
||||||
case "reopen" if (issue.closed) =>
|
case "reopen" if (issue.closed) =>
|
||||||
false ->
|
false ->
|
||||||
(Some("reopen") -> Some(recordReopenIssueActivity _))
|
(Some("reopen") -> Some(
|
||||||
|
if (issue.isPullRequest) recordReopenPullRequestActivity _
|
||||||
|
else recordReopenIssueActivity _
|
||||||
|
))
|
||||||
}
|
}
|
||||||
.map {
|
.map {
|
||||||
case (closed, t) =>
|
case (closed, t) =>
|
||||||
|
|||||||
Reference in New Issue
Block a user