summaryrefslogtreecommitdiffstats
path: root/models/action.go
diff options
context:
space:
mode:
authorUnknown <joe2010xtmf@163.com>2014-03-23 06:27:01 -0400
committerUnknown <joe2010xtmf@163.com>2014-03-23 06:27:01 -0400
commit1eb078d0a8c5424de9512d810ab2fbf21f59ff78 (patch)
treede429367cb1efd971d6d6723882dc793fe05a733 /models/action.go
parent24630e0c9b92bcd9fdeb07ce15c3dd2cfc459a52 (diff)
downloadgitea-1eb078d0a8c5424de9512d810ab2fbf21f59ff78.tar.gz
gitea-1eb078d0a8c5424de9512d810ab2fbf21f59ff78.zip
Fix action
Diffstat (limited to 'models/action.go')
-rw-r--r--models/action.go12
1 files changed, 6 insertions, 6 deletions
diff --git a/models/action.go b/models/action.go
index ca2ff3cbf1..1174929354 100644
--- a/models/action.go
+++ b/models/action.go
@@ -8,6 +8,7 @@ import (
"encoding/json"
"time"
+ "github.com/gogits/gogs/modules/base"
"github.com/gogits/gogs/modules/log"
)
@@ -47,18 +48,17 @@ func (a Action) GetRepoName() string {
return a.RepoName
}
-func (a Action) GetContent() string {
- return a.Content
+func (a Action) GetBranch() string {
+ return a.RefName
}
-type PushCommits struct {
- Len int
- Commits [][]string
+func (a Action) GetContent() string {
+ return a.Content
}
// CommitRepoAction records action for commit repository.
func CommitRepoAction(userId int64, userName string,
- repoId int64, repoName string, refName string, commits *PushCommits) error {
+ repoId int64, repoName string, refName string, commits *base.PushCommits) error {
bs, err := json.Marshal(commits)
if err != nil {
return err