This commit is contained in:
crusader 2018-03-27 00:15:09 +09:00
parent a02f6e011c
commit ec39167968

View File

@ -18,13 +18,13 @@ func ExecuteStarters(instances []interface{}, targetTypes []reflect.Type, revers
}
if reverse {
for indexI := ilen - 1; indexI >= 0; indexI-- {
for indexI := tlen - 1; indexI >= 0; indexI-- {
if err := executeStarter(instances, targetTypes[indexI]); nil != err {
return err
}
}
} else {
for indexI := 0; indexI < ilen; indexI++ {
for indexI := 0; indexI < tlen; indexI++ {
if err := executeStarter(instances, targetTypes[indexI]); nil != err {
return err
}
@ -59,13 +59,13 @@ func ExecuteStoppers(instances []interface{}, targetTypes []reflect.Type, revers
}
if reverse {
for indexI := ilen - 1; indexI >= 0; indexI-- {
for indexI := tlen - 1; indexI >= 0; indexI-- {
if err := executeStarter(instances, targetTypes[indexI]); nil != err {
return err
}
}
} else {
for indexI := 0; indexI < ilen; indexI++ {
for indexI := 0; indexI < tlen; indexI++ {
if err := executeStarter(instances, targetTypes[indexI]); nil != err {
return err
}