diff options
-rw-r--r-- | index.js | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/index.js b/index.js index 0c2039c..b53ef73 100644 --- a/index.js +++ b/index.js @@ -44,14 +44,12 @@ function cycle() { }); }); } -var api_url = process.env.INSTANCE_HOST + '/api/v1'; -console.log('Now initializing mastodon API with token', process.env.AMBASSADOR_TOKEN, 'and api url', api_url); + var M = new mastodon({ access_token: process.env.AMBASSADOR_TOKEN, - api_url: api_url + api_url: process.env.INSTANCE_HOST }); - var boosted = {}; function boost(rows) { rows.map(function(row) { @@ -68,7 +66,7 @@ function boost(rows) { return console.log('Warning: tried to boost #' + id + ' but it had already been boosted by this account. Adding to cache.'); } - return console.error(err); + return console.log(err); } boosted[id] = true; console.log('boosted status #' + id); |