We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent af56766 commit ea9cc4fCopy full SHA for ea9cc4f
20 files changed
.circleci/docker-compose.yml
@@ -1,7 +1,7 @@
1
version: '3'
2
services:
3
stardog1:
4
- command: ["--port", "5821", "--home", "/var/opt/stardog"]
+ command: ['--port', '5821', '--home', '/var/opt/stardog']
5
depends_on:
6
- zoo1
7
environment:
@@ -18,7 +18,7 @@ services:
18
- ../stardog-license-key.bin:/var/opt/stardog/stardog-license-key.bin
19
- ./cluster.properties:/var/opt/stardog/stardog.properties
20
stardog2:
21
- command: ["--port", "5822", "--home", "/var/opt/stardog"]
+ command: ['--port', '5822', '--home', '/var/opt/stardog']
22
23
24
@@ -71,7 +71,6 @@ services:
71
working_dir: /app
72
73
- HOST=stardog1
74
- - CIRCLECI=true
75
volumes:
76
- ../:/app/
77
.circleci/jwt.yaml
@@ -1,13 +1,13 @@
---
-confVersion: "1.0"
+confVersion: '1.0'
deploymentName: stardog-server
issuers:
http://stardog.com:
algorithms:
HS256:
8
- secret: "some-kind-of-secret-key-here"
+ secret: 'some-kind-of-secret-key-here'
9
10
signer:
11
algorithm: HS256
12
13
issuer: http://stardog.com
.eslintrc.js
@@ -31,6 +31,5 @@ module.exports = {
31
32
// TODO remove these:
33
'no-unused-vars': 'off',
34
- 'prefer-object-spread': 'warn',
35
},
36
};
.vscode/settings.json
lib/Connection.js
@@ -10,7 +10,7 @@ class Connection {
// request creation can be overriden by providing a `createRequest` method on
// `meta`, and header creation can be overriden with `createHeaders`.
config(options, meta) {
- const config = Object.assign({}, this, options, { meta });
+ const config = { ...this, ...options, meta };
14
15
// If it ends with / slice it off
16
if (
lib/catalog.js
@@ -22,7 +22,7 @@ const addCredential = (conn, credentials, label) => {
const headers = conn.headers();
headers.set('Content-Type', 'application/json');
25
- const body = Object.assign({}, credentials, { label });
+ const body = { ...credentials, label };
26
27
return fetch(conn.request('admin', 'catalog', 'credentials'), {
28
method: 'POST',
lib/db/index.js
@@ -7,14 +7,13 @@ const reasoning = require('./reasoning');
const docs = require('./docs');
const namespaces = require('./namespaces');
-module.exports = Object.assign(
- {},
- db,
- { icv },
- { transaction },
- { options },
- { docs },
17
- { graph },
- { reasoning },
- { namespaces }
-);
+module.exports = {
+ ...db,
+ icv,
+ transaction,
+ options,
+ docs,
+ graph,
+ reasoning,
+ namespaces,
+};
lib/db/main.js
@@ -28,9 +28,7 @@ const dispatchChange = (conn, config, content, params = {}) => {
}
29
)
30
.then(httpBody)
- .then(res =>
- Object.assign({}, res, { transactionId: config.transactionId })
- );
+ .then(res => ({ ...res, transactionId: config.transactionId }));
const create = (conn, database, databaseOptions = {}, options = {}, params) => {
@@ -151,7 +149,7 @@ const clear = (conn, database, transactionId, params = {}) => {
151
149
152
150
153
154
- .then(res => Object.assign({}, res, { transactionId }));
+ .then(res => ({ ...res, transactionId }));
155
156
157
// options - graphUri, contentType, encoding
lib/db/namespaces.js
@@ -10,7 +10,7 @@ const backwardsCompatGetNamespaces = (conn, database) =>
const n = lodashGet(res, 'body.database.namespaces', []);
const names = n.reduce((memo, keyValString) => {
const [key, value] = keyValString.split('=');
- return Object.assign({}, memo, { [key]: value });
+ return { ...memo, [key]: value };
}, {});
res.body = names;
@@ -29,15 +29,13 @@ const get = (conn, database) => {
return backwardsCompatGetNamespaces(conn, database);
- return httpBody(res).then(bodyRes =>
- Object.assign({}, bodyRes, {
- body: lodashGet(bodyRes, 'body.namespaces', []).reduce(
- (memo, { prefix, name }) =>
- Object.assign({}, memo, { [prefix]: name }),
37
- {}
38
- ),
39
- })
40
+ return httpBody(res).then(bodyRes => ({
+ ...bodyRes,
+ body: lodashGet(bodyRes, 'body.namespaces', []).reduce(
+ (memo, { prefix, name }) => ({ ...memo, [prefix]: name }),
+ {}
+ ),
+ }));
41
});
42
43
lib/db/transaction.js
@@ -1,7 +1,6 @@
const { httpBody } = require('../response-transforms');
-const attachTransactionId = transactionId => res =>
- Object.assign({}, res, { transactionId });
+const attachTransactionId = transactionId => res => ({ ...res, transactionId });
const begin = (conn, database, params = {}) => {
@@ -11,7 +10,7 @@ const begin = (conn, database, params = {}) => {
headers,
})
- .then(res => Object.assign({}, res, { transactionId: res.body }));
+ .then(res => ({ ...res, transactionId: res.body }));
const rollback = (conn, database, transactionId, params = {}) => {
0 commit comments