Replaces Promise to compatible with Promises/A+ stuff

(see http://promises-aplus.github.io/promises-spec/ for spec)