fix bugs.

Signed-off-by: PedroLourenco <pdrolourenco@gmail.com>