diff --git a/lib/alias.js b/lib/alias.js index fe17698..e68b1a0 100644 --- a/lib/alias.js +++ b/lib/alias.js @@ -1,12 +1,10 @@ -import retry from './retry'; +import retry from 'async-retry'; import Now from '../lib'; export default class Alias extends Now { - async ls (url) { - console.log('list', url); - const deploymentId = url; // TODO get from API + async ls () { return retry(async (bail) => { - const res = await this._fetch(`/now/aliases/${deploymentId}/`); + const res = await this._fetch('/now/aliases'); if (200 !== res.status && (400 <= res.status || 500 > res.status)) { if (this._debug) console.log('> [debug] bailing on creating due to %s', res.status);