diff options
author | Michael Muré <batolettre@gmail.com> | 2019-02-18 14:11:37 +0100 |
---|---|---|
committer | Michael Muré <batolettre@gmail.com> | 2019-03-01 22:40:26 +0100 |
commit | 947ea63522610bd16c32cf70812c129eda9bbb02 (patch) | |
tree | 76542e4a5ab488dc45477d33c3f4e94b0eb36975 /cache/bug_excerpt.go | |
parent | 976af3a4e8382d03e9f2ccb57e2ed3b783294138 (diff) | |
download | git-bug-947ea63522610bd16c32cf70812c129eda9bbb02.tar.gz git-bug-947ea63522610bd16c32cf70812c129eda9bbb02.zip |
identity: wip caching
Diffstat (limited to 'cache/bug_excerpt.go')
-rw-r--r-- | cache/bug_excerpt.go | 20 |
1 files changed, 6 insertions, 14 deletions
diff --git a/cache/bug_excerpt.go b/cache/bug_excerpt.go index daf89c4f..d3645322 100644 --- a/cache/bug_excerpt.go +++ b/cache/bug_excerpt.go @@ -17,18 +17,13 @@ type BugExcerpt struct { CreateUnixTime int64 EditUnixTime int64 - Status bug.Status - Author AuthorExcerpt - Labels []bug.Label + Status bug.Status + AuthorId string + Labels []bug.Label CreateMetadata map[string]string } -type AuthorExcerpt struct { - Name string - Login string -} - func NewBugExcerpt(b bug.Interface, snap *bug.Snapshot) *BugExcerpt { return &BugExcerpt{ Id: b.Id(), @@ -37,12 +32,9 @@ func NewBugExcerpt(b bug.Interface, snap *bug.Snapshot) *BugExcerpt { CreateUnixTime: b.FirstOp().GetUnixTime(), EditUnixTime: snap.LastEditUnix(), Status: snap.Status, - Author: AuthorExcerpt{ - Login: snap.Author.Login(), - Name: snap.Author.Name(), - }, - Labels: snap.Labels, - CreateMetadata: b.FirstOp().AllMetadata(), + AuthorId: snap.Author.Id(), + Labels: snap.Labels, + CreateMetadata: b.FirstOp().AllMetadata(), } } |