Skip to content

Commit 7ccb5de

Browse files
committed
Fixed neo4j communication in ai-assistant
1 parent 54742a5 commit 7ccb5de

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

ai-assistant/src/core/db/neo4j.ts

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -36,9 +36,9 @@ export class Neo4j implements IDB {
3636
// this.baseUrl = "http://neo4j:7474";
3737
// this.username = "neo4j";
3838
// this.password = "strongpasswordsafe123";
39-
this.baseUrl = "http://3.89.86.217:7474";
39+
this.baseUrl = "http://34.230.47.155:7474";
4040
this.username = "neo4j";
41-
this.password = "errors-fourths-seeds";
41+
this.password = "talk-runway-pad";
4242
}
4343

4444
private async sendRequest(
@@ -58,12 +58,14 @@ export class Neo4j implements IDB {
5858
headers,
5959
data: data,
6060
});
61+
6162
if (!res || ![200, 201].includes(res.statusCode) || !res.content) {
62-
console.log(res);
6363
return null;
6464
}
65+
const parsedContent = JSON.parse(res.content);
66+
if (parsedContent.errors.length) return null;
6567

66-
return JSON.parse(res.content);
68+
return parsedContent;
6769
}
6870

6971
async verifyConnectivity(): Promise<void> {

0 commit comments

Comments
 (0)