File tree Expand file tree Collapse file tree 7 files changed +62
-12
lines changed Expand file tree Collapse file tree 7 files changed +62
-12
lines changed Original file line number Diff line number Diff line change 1919
2020import { int , isInt } from './v1/integer' ;
2121import Driver from './v1/driver' ;
22+ import VERSION from './version' ;
23+ import * as v1 from './v1/index.js' ;
2224
23- let USER_AGENT = "neo4j-javascript/0.0" ;
25+ let USER_AGENT = "neo4j-javascript/" + VERSION ;
26+
27+ console . log ( v1 ) ;
2428
2529export default {
26- v1 : {
27- driver : ( url ) => new Driver ( url , USER_AGENT ) ,
28- int : int ,
29- isInt : isInt
30- }
30+ v1 : v1
3131}
Original file line number Diff line number Diff line change 1+ /**
2+ * Copyright (c) 2002-2015 "Neo Technology,"
3+ * Network Engine for Objects in Lund AB [http://neotechnology.com]
4+ *
5+ * This file is part of Neo4j.
6+ *
7+ * Licensed under the Apache License, Version 2.0 (the "License");
8+ * you may not use this file except in compliance with the License.
9+ * You may obtain a copy of the License at
10+ *
11+ * http://www.apache.org/licenses/LICENSE-2.0
12+ *
13+ * Unless required by applicable law or agreed to in writing, software
14+ * distributed under the License is distributed on an "AS IS" BASIS,
15+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16+ * See the License for the specific language governing permissions and
17+ * limitations under the License.
18+ */
19+
20+ import { int , isInt } from './integer' ;
21+ import Driver from './driver' ;
22+ import { VERSION } from '../version' ;
23+
24+ let USER_AGENT = "neo4j-javascript/" + VERSION ;
25+
26+ export default {
27+ driver : ( url ) => new Driver ( url , USER_AGENT ) ,
28+ int : int ,
29+ isInt : isInt
30+ }
Original file line number Diff line number Diff line change 1717 * limitations under the License.
1818 */
1919
20- import neo4j from '../index ' ;
20+ import { int , isInt } from './integer ' ;
2121
2222/**
2323 * A ResultSummary instance contains structured metadata for a {Result}.
@@ -126,7 +126,7 @@ class StatementStatistics {
126126 constraintsRemoved : 0
127127 }
128128 Object . keys ( statistics ) . forEach ( ( index ) => {
129- let val = neo4j . v1 . isInt ( statistics [ index ] ) ? statistics [ index ] . toInt ( ) : statistics [ index ] ;
129+ let val = isInt ( statistics [ index ] ) ? statistics [ index ] . toInt ( ) : statistics [ index ] ;
130130 //To camelCase
131131 this . _stats [ index . replace ( / ( \- \w ) / g, ( m ) => m [ 1 ] . toUpperCase ( ) ) ] = val ;
132132 } ) ;
Original file line number Diff line number Diff line change 1+ /**
2+ * Copyright (c) 2002-2015 "Neo Technology,"
3+ * Network Engine for Objects in Lund AB [http://neotechnology.com]
4+ *
5+ * This file is part of Neo4j.
6+ *
7+ * Licensed under the Apache License, Version 2.0 (the "License");
8+ * you may not use this file except in compliance with the License.
9+ * You may obtain a copy of the License at
10+ *
11+ * http://www.apache.org/licenses/LICENSE-2.0
12+ *
13+ * Unless required by applicable law or agreed to in writing, software
14+ * distributed under the License is distributed on an "AS IS" BASIS,
15+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16+ * See the License for the specific language governing permissions and
17+ * limitations under the License.
18+ */
19+
20+ export default { VERSION : "0.0.0-dev" } ;
Original file line number Diff line number Diff line change 1717 * limitations under the License.
1818 */
1919
20- var neo4j = require ( "../lib/index" ) . v1 ;
20+ var neo4j = require ( "../../ lib/v1" ) ;
2121
2222describe ( 'driver' , function ( ) {
2323 it ( 'should expose sessions' , function ( ) {
Original file line number Diff line number Diff line change 1717 * limitations under the License.
1818 */
1919
20- var neo4j = require ( "../lib/index" ) . v1 ;
21- var StatementType = require ( "../lib/v1/result-summary" ) . statementType ;
20+ var neo4j = require ( "../../ lib/v1" ) ;
21+ var StatementType = require ( "../../ lib/v1/result-summary" ) . statementType ;
2222
2323describe ( 'session' , function ( ) {
2424 it ( 'should expose basic run/subscribe ' , function ( done ) {
Original file line number Diff line number Diff line change 1717 * limitations under the License.
1818 */
1919
20- var neo4j = require ( "../lib/index" ) . v1 ;
20+ var neo4j = require ( "../../ lib/v1" ) ;
2121
2222describe ( 'floating point values' , function ( ) {
2323 it ( 'should support float 1.0 ' , testVal ( 1 ) ) ;
You can’t perform that action at this time.
0 commit comments