Refactor github example