Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

error-service

Package Overview
Dependencies
Maintainers
1
Versions
12
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

error-service - npm Package Compare versions

Comparing version 1.0.1 to 1.0.2

2

package.json
{
"name": "error-service",
"version": "1.0.1",
"version": "1.0.2",
"description": "functions required to display errors",

@@ -5,0 +5,0 @@ "main": "index.js",

@@ -24,2 +24,23 @@ class ErrorQueries {

getStartNodeOfRelationship = {
query: `
MATCH (n1:User)
WHERE n1.facebookId = $fromFacebookId AND n1.recentFacebookAccessToken = $fromFacebookAccessToken
WITH n1
MATCH (n2:User)
WHERE n2.id = $toId AND n1.id <> $toId
WITH n1,n2
OPTIONAL MATCH (n1)-[r]-(n2)
WITH n1,n2,r
RETURN startNode(r)
`,
params: function (fromFacebookId, fromFacebookAccessToken, toId) {
return {
fromFacebookId: fromFacebookId,
fromFacebookAccessToken: fromFacebookAccessToken,
toId: toId
};
}
};
areUsersFriendsWithMe = {

@@ -26,0 +47,0 @@ query: `

@@ -26,2 +26,17 @@ const { ErrorQueries } = require("./../queries/ErrorQueries.js")

getStartNodeOfRelationship(fromFacebookId, fromFacebookAccessToken, toId) {
return executeQuery(errorQueries.getStartNodeOfRelationship.query, errorQueries.getStartNodeOfRelationship.params(fromFacebookId, fromFacebookAccessToken, toId), this.driver)
.then(records => {
if (records[0]) {
if (records[0][0] != null) {
return records[0][0];
}
}
})
.catch(error => {
console.log(error);
return { "error": error.toString() };
});
}
areUsersFriendsWithMe(facebookId, facebookAccessToken, taggedUserIdArray) {

@@ -28,0 +43,0 @@ return executeQuery(errorQueries.areUsersFriendsWithMe.query, errorQueries.areUsersFriendsWithMe.params(facebookId, facebookAccessToken, taggedUserIdArray), this.driver)

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc