Extract some functionality into a new features module