所以,我有下面的代码:
const { Database, aql } = require("arangojs");
const db = new Database({·
url: 'http://127.0.0.1:8529'
} );
db.useBasicAuth('root', 'password1')
(async function() {
const now = Date.now();
try {
const cursor = await db.query(aql`RETURN ${now}`);
const result = await cursor.next();
} catch (err) { console.log(err) }
})();
这给了我一个错误:
TypeError: db.useBasicAuth(...) is not a function
驱动版本为:
"arangojs": "^6.3.0"
有任何想法吗?