Skip to content

Commit

Permalink
RSDK-4457 - Use web context when adding new camera streams (#2782)
Browse files Browse the repository at this point in the history
  • Loading branch information
cheukt authored and stevebriskin committed Aug 14, 2023
1 parent 6036fd0 commit 62d89fa
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion robot/web/web.go
Original file line number Diff line number Diff line change
Expand Up @@ -454,7 +454,10 @@ func (svc *webService) Reconfigure(ctx context.Context, deps resource.Dependenci
if err := svc.updateResources(deps); err != nil {
return err
}
return svc.addNewStreams(ctx)
if !svc.isRunning {
return nil
}
return svc.addNewStreams(svc.cancelCtx)
}

func (svc *webService) updateResources(resources map[resource.Name]resource.Resource) error {
Expand Down

0 comments on commit 62d89fa

Please sign in to comment.