Refactor cancel subscription