Refactor app path logic in push