fixing several problems.

Signed-off-by: Nico Magni <nicomagni@wolox.com.ar>