Adding custom polyfill until I find a better alternative: