Add helper method.
Some refactoring.
Add a based on note.