Merge pull request #2148 from Human-Connection/2128-close-all-sessions

close all open sessions
This commit is contained in:
mattwr18 2019-11-07 10:05:59 +01:00 committed by GitHub
commit cb2b8ddad7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 4 additions and 0 deletions

View File

@ -56,6 +56,7 @@ const createLocation = async (session, mapboxData) => {
query += ' RETURN l.id'
await session.run(query, data)
session.close()
}
const createOrUpdateLocations = async (userId, locationName, driver) => {

View File

@ -72,6 +72,7 @@ const validateReport = async (resolve, root, args, context, info) => {
submitterId: user.id,
},
)
session.close()
const [existingReportedResource] = reportQueryRes.records.map(record => {
return {
label: record.get('label'),

View File

@ -59,6 +59,7 @@ export default {
`,
{ commentId: args.id },
)
session.close()
const [comment] = transactionRes.records.map(record => record.get('comment').properties)
return comment
},

View File

@ -182,6 +182,7 @@ export default {
`,
{ postId: args.id },
)
session.close()
const [post] = transactionRes.records.map(record => record.get('post').properties)
return post
},