Fix variable reference error.
Add whitelist validator.
Move validation into package.
Change default values for sort and tags.