Added promise support using ypromise as a polyfill