Comparing version 1.0.2 to 1.0.3
@@ -47,8 +47,13 @@ 'use strict'; | ||
const protocol = this.options.protocol || `${host === 'localhost' ? 'http' : 'https'}`; | ||
const url = this.options.url || `${protocol}://${username}:${password}@${host}:${port}`; | ||
const rejectUnauthorized = this.options.rejectUnauthorized === false ? false : true; | ||
const db = (0, _arangojs2.default)({ | ||
url | ||
const db = new _arangojs.Database({ | ||
url: `${protocol}://${host}:${port}`, | ||
agentOptions: { | ||
rejectUnauthorized | ||
} | ||
}); | ||
db.useBasicAuth(username, password); | ||
try { | ||
@@ -55,0 +60,0 @@ await db.createDatabase(dbName); |
@@ -1,2 +0,2 @@ | ||
import arangojs, { aql } from 'arangojs' | ||
import arangojs, { Database, aql } from 'arangojs' | ||
import Schema from '../schemas/schema' | ||
@@ -33,8 +33,13 @@ import { get, keys } from 'lodash' | ||
const protocol = this.options.protocol || `${host === 'localhost' ? 'http' : 'https'}` | ||
const url = this.options.url || `${protocol}://${username}:${password}@${host}:${port}` | ||
const rejectUnauthorized = this.options.rejectUnauthorized === false ? false : true | ||
const db = arangojs({ | ||
url | ||
const db = new Database({ | ||
url: `${protocol}://${host}:${port}`, | ||
agentOptions: { | ||
rejectUnauthorized | ||
} | ||
}) | ||
db.useBasicAuth(username, password) | ||
try { | ||
@@ -41,0 +46,0 @@ await db.createDatabase(dbName) |
{ | ||
"name": "final-orm", | ||
"version": "1.0.2", | ||
"version": "1.0.3", | ||
"repository": { | ||
@@ -5,0 +5,0 @@ "type": "git", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
262007
2142