implements a fix proposed by @dlukez to my issue https://github.com/angular-ui/ui-router/issues/558 on top of the older, stable v0.2.0 release so that we can use it the fix in production until it gets merged into master as part of a new release.