Fix previous TODOs with generic