Fix functions, return types, types, indentation