async function should have await expression JS-0116
Bug risk
Minor
4 months ago3 years old
Found async function without any await expressions
 64        result.should.have.properties(testPost)
 65      })
 66
 67      it('clears listeners', async () => { 68        blurt.api.listeners('message').should.have.lengthOf(0) 69      }) 70    })
 71  })
 72
Found async function without any await expressions
 48        result1.should.not.be.eql(result2)
 49      })
 50
 51      it('clears listeners', async () => { 52        blurt.api.listeners('message').should.have.lengthOf(0) 53      }) 54    })
 55  })
 56
Found async function without any await expressions
216  res.sendFile('favicon.ico', { root: assetsPath })
217})
218
219router.get('/', async (req, res, next) => {220  res.set('Cache-Control', 'no-cache')221  res.status(200).json({ ok: true, version: '1.1.0', date: new Date() })222})223
224const debug_sharp = () => {
225  const stats = sharp.cache()
Found async function without any await expressions
210  }
211})
212
213router.get('/favicon.ico', async (req, res, next) => {214  res.set('content-type', 'image/x-icon')215  res.set('Cache-Control', 'public,max-age=209030400,immutable')216  res.sendFile('favicon.ico', { root: assetsPath })217})218
219router.get('/', async (req, res, next) => {
220  res.set('Cache-Control', 'no-cache')
Found async function without any await expressions
149
150  const router = express.Router()
151  router.post('/:username/:sig', hdl_upload_s3)
152  router.get('/test_cors', async (req, res) => {153    res.json({ status: 'ok', message: 'success', data: null })154  })155
156  router.get('/', function (req, res) {
157    peers().then(res.send)