diff --git a/types/arangodb/arangodb-tests.ts b/types/arangodb/arangodb-tests.ts index e049a2374d..c2ade4d0bb 100644 --- a/types/arangodb/arangodb-tests.ts +++ b/types/arangodb/arangodb-tests.ts @@ -16,6 +16,9 @@ coll.save({ username: "user" }); const doc = coll.any(); console.log(doc.username); +const coll2 = db._collection(coll.name()); +console.log(coll2 === coll); + const users = coll as ArangoDB.Collection; const admin = users.firstExample({ username: "admin" })!; users.update(admin, { password: md5("hunter2") }); diff --git a/types/arangodb/index.d.ts b/types/arangodb/index.d.ts index 238cea2379..c5e83a1cfc 100644 --- a/types/arangodb/index.d.ts +++ b/types/arangodb/index.d.ts @@ -619,6 +619,7 @@ declare namespace ArangoDB { interface Collection { // Collection + name(): string; checksum( withRevisions?: boolean, withData?: boolean @@ -1503,16 +1504,7 @@ declare module "@arangodb/foxx/queues" { function deleteQueue(name: string): boolean; function get(name: string): Queue; - export { - createQueue as create, - deleteQueue as delete, - get, - JobOptions, - Job, - Queue, - QueueItem, - Script, - }; + export { createQueue as create, deleteQueue as delete, get, JobOptions, Job, Queue, QueueItem, Script, }; } declare module "@arangodb/foxx/graphql" {