Replaced depreciated method clearCache() with refresh()

This also includes the pull request from romain here: https://github.com/dannevang/babel/commit/1e5d980f19777748aafb13097071857cb0606422