Skip to content

Commit

Permalink
Merge pull request #1254 from huone1/fix/scheduler
Browse files Browse the repository at this point in the history
[scheduler]fix a defer execution sequence problem
  • Loading branch information
karmada-bot authored Jan 14, 2022
2 parents bc15b3d + 4c9bfbf commit 4089758
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions pkg/scheduler/scheduler.go
Original file line number Diff line number Diff line change
Expand Up @@ -396,7 +396,7 @@ func (s *Scheduler) doSchedule(key string) error {
return s.doScheduleClusterBinding(name)
}

func (s *Scheduler) doScheduleBinding(namespace, name string) error {
func (s *Scheduler) doScheduleBinding(namespace, name string) (err error) {
rb, err := s.bindingLister.ResourceBindings(namespace).Get(name)
if err != nil {
if apierrors.IsNotFound(err) {
Expand Down Expand Up @@ -458,7 +458,7 @@ func (s *Scheduler) doScheduleBinding(namespace, name string) error {
return nil
}

func (s *Scheduler) doScheduleClusterBinding(name string) error {
func (s *Scheduler) doScheduleClusterBinding(name string) (err error) {
crb, err := s.clusterBindingLister.Get(name)
if err != nil {
if apierrors.IsNotFound(err) {
Expand Down

0 comments on commit 4089758

Please sign in to comment.