Removed return statement in flatMap