removeVisit = async function (url) {
  // validate parameters
  if (!url || typeof url !== 'string') {
    throw new BadParamError('url must be a string')
  }

  var release = await lock('history-db')
  try {
    db.serialize()
    db.run('BEGIN TRANSACTION;')
    db.run('DELETE FROM visits WHERE url = ?;', url)
    db.run('DELETE FROM visit_stats WHERE url = ?;', url)
    db.run('DELETE FROM visit_fts WHERE url = ?;', url)
    await db.run('COMMIT;')
  } catch (e) {
    await db.run('ROLLBACK;')
    throw e
  } finally {
    db.parallelize()
    release()
  }
}
@param {string} url
@returns {Promise<void>}