I'm currently attempting to update a URL without having to refresh my page, and I came across this solution that I am working with: https://github.com/angular/angular.js/issues/1699#issuecomment-45048054
Upon further testing, I found that the following code is effective:
$route.current.pathParams.program = "someValue";
$location.path('/myapp/' + $routeParams.program);
However, when trying the following code, it does NOT work:
$routeParams.program = "someValue";
$location.path('/myapp/' + $routeParams.program);
I'm curious about what the distinction is between these two codes and why one is successful while the other is not?