diff options
| author | Dmitry Vyukov <dvyukov@google.com> | 2020-09-29 13:01:04 +0200 |
|---|---|---|
| committer | Dmitry Vyukov <dvyukov@google.com> | 2020-09-30 18:19:39 +0200 |
| commit | 1fa82c3b3d0045834180bf1c3983afbdf5f0006e (patch) | |
| tree | 4f0dbf8bbb22029fea319090595eb9f94c1441c2 /dashboard/dashapi/dashapi.go | |
| parent | a08a401275245df9414b39a60382335a52a0942b (diff) | |
dashboard/app: return BugReport from load_bug API
Return BugReport instead of LoadBugResp from load_bug API request.
LoadBugResp is some limited subset of info in BugReport (mostly),
it's useful to have just one type to describe bug with all needed info.
Update #2144
Diffstat (limited to 'dashboard/dashapi/dashapi.go')
| -rw-r--r-- | dashboard/dashapi/dashapi.go | 15 |
1 files changed, 2 insertions, 13 deletions
diff --git a/dashboard/dashapi/dashapi.go b/dashboard/dashapi/dashapi.go index 7e5b18cf9..a1c5c0f63 100644 --- a/dashboard/dashapi/dashapi.go +++ b/dashboard/dashapi/dashapi.go @@ -507,20 +507,9 @@ type LoadBugReq struct { ID string } -type LoadBugResp struct { - ID string - Title string - Status string - SyzkallerCommit string - Arch string - ReproOpts []byte - ReproSyz []byte - ReproC []byte -} - -func (dash *Dashboard) LoadBug(id string) (*LoadBugResp, error) { +func (dash *Dashboard) LoadBug(id string) (*BugReport, error) { req := LoadBugReq{id} - resp := new(LoadBugResp) + resp := new(BugReport) err := dash.Query("load_bug", req, resp) return resp, err } |
