Refactor addon command to inherit from new.

Removes duplication.