Using Promise instead of promise, fix promises