Convert method to promise
Fix doc