Move a duplicate complex method out of multiple classes into a module.