do not loop when it's not necessary

The parameters are get twice. This is not necessary...