Move boilerplate to utility module.