updated function call, return etc.
removed extra return (unreachable).