Corrected errors

Corrected some forgotten changes which interrupted the script. It should
work better now...