formatted

This commit is contained in:
Abhinav Adduri 2017-06-08 15:02:00 -07:00
parent 6cb1fc433e
commit 5fe901e31d
2 changed files with 2 additions and 4 deletions

View File

@ -35,7 +35,7 @@ app.get('/exists/:id', (req, res) => {
let id = req.params.id;
storage.exists(id).then(doesExist => {
res.sendStatus(doesExist ? 200 : 404);
})
});
});
app.get('/download/:id', (req, res) => {

View File

@ -7,7 +7,6 @@ const path = require('path');
const fetch = require('node-fetch');
const crypto = require('crypto');
let notLocalHost = conf.notLocalHost;
const mozlog = require('./log.js');
@ -19,7 +18,6 @@ const redis_client = redis.createClient({
host: conf.redis_host
});
redis_client.on('error', err => {
log.info('Redis: ', err);
});
@ -61,7 +59,7 @@ function filename(id) {
function exists(id) {
return new Promise((resolve, reject) => {
redis_client.exists(id, (rediserr, reply) => {
resolve(reply === 1)
resolve(reply === 1);
});
});
}