fix($$RAFProvider)

Joined fix for:
https://github.com/angular/angular.js/pull/6542
https://github.com/angular/angular.js/pull/6540