Extract common logic into independent module.