fix loop race condition

This commit is contained in:
rxdn 2020-06-19 21:26:24 +01:00
parent de1d41da05
commit c82bf220cf

View File

@ -38,7 +38,8 @@ func ListPanels(ctx *gin.Context) {
group, _ := errgroup.WithContext(context.Background()) group, _ := errgroup.WithContext(context.Background())
for i, p := range panels { for i, p := range panels {
group.Go(func() (err error) { i := i
group.Go(func() error {
var mentions []string var mentions []string
// get role mentions // get role mentions