Refactor calculating snapshot differences