mirror of
https://github.com/cuigh/swirl
synced 2025-06-04 03:36:27 +00:00
Fix error handling
This commit is contained in:
parent
4e698446e8
commit
db4311f669
@ -311,11 +311,16 @@ func serviceStats(ctx web.Context) error {
|
||||
if dashboard, err = biz.Chart.GetDashboard("service", name); err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
if dashboard == nil {
|
||||
charts, err = biz.Chart.GetServiceCharts(name)
|
||||
} else {
|
||||
charts, err = biz.Chart.GetDashboardCharts(dashboard)
|
||||
}
|
||||
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
|
||||
period := cast.ToDuration(ctx.Q("time"), time.Hour)
|
||||
|
Loading…
Reference in New Issue
Block a user