fixed Go function definition