mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
Image-rendering: Cleanup of rendering code (#20496)
This commit is contained in:
@@ -96,16 +96,14 @@ func (rs *RenderingService) RenderErrorImage(err error) (*RenderResult, error) {
|
||||
imgUrl := "public/img/rendering_error.png"
|
||||
|
||||
return &RenderResult{
|
||||
FilePath: filepath.Join(setting.HomePath, imgUrl),
|
||||
KeepFileAfterRender: true,
|
||||
FilePath: filepath.Join(setting.HomePath, imgUrl),
|
||||
}, nil
|
||||
}
|
||||
|
||||
func (rs *RenderingService) Render(ctx context.Context, opts Opts) (*RenderResult, error) {
|
||||
if rs.inProgressCount > opts.ConcurrentLimit {
|
||||
return &RenderResult{
|
||||
FilePath: filepath.Join(setting.HomePath, "public/img/rendering_limit.png"),
|
||||
KeepFileAfterRender: true,
|
||||
FilePath: filepath.Join(setting.HomePath, "public/img/rendering_limit.png"),
|
||||
}, nil
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user