fix indentations in functions