summaryrefslogtreecommitdiffstats
path: root/models
diff options
context:
space:
mode:
authorUnknwon <u@gogs.io>2015-08-19 20:08:57 +0800
committerUnknwon <u@gogs.io>2015-08-19 20:08:57 +0800
commit1453e91f419e52fc74e3ec51b47a080a27a33342 (patch)
treee8bb9e381999b6a8a09685af003ed7580da2a116 /models
parent2b393f5b039db177a58be03f1c5c746eac501686 (diff)
downloadgitea-1453e91f419e52fc74e3ec51b47a080a27a33342.tar.gz
gitea-1453e91f419e52fc74e3ec51b47a080a27a33342.zip
minor fix on API response
Diffstat (limited to 'models')
-rw-r--r--models/access.go2
-rw-r--r--models/migrations/migrations.go2
2 files changed, 2 insertions, 2 deletions
diff --git a/models/access.go b/models/access.go
index 8d698f151d..917f1c280d 100644
--- a/models/access.go
+++ b/models/access.go
@@ -68,7 +68,7 @@ func HasAccess(u *User, repo *Repository, testMode AccessMode) (bool, error) {
}
// GetAccessibleRepositories finds all repositories where a user has access to,
-// besides his own.
+// besides he/she owns.
func (u *User) GetAccessibleRepositories() (map[*Repository]AccessMode, error) {
accesses := make([]*Access, 0, 10)
if err := x.Find(&accesses, &Access{UserID: u.Id}); err != nil {
diff --git a/models/migrations/migrations.go b/models/migrations/migrations.go
index f1d6c91af5..08a503e6da 100644
--- a/models/migrations/migrations.go
+++ b/models/migrations/migrations.go
@@ -470,7 +470,7 @@ func trimCommitActionAppUrlPrefix(x *xorm.Engine) error {
if _, err = sess.Id(actID).Update(&Action{
Content: string(p),
}); err != nil {
- return fmt.Errorf("update action[%s]: %v", actID, err)
+ return fmt.Errorf("update action[%d]: %v", actID, err)
}
}
return sess.Commit()