fix(server): theoretically filters out subs from telemetry

This commit is contained in:
Dimitrie Stefanescu
2021-05-17 14:45:13 +01:00
parent 95736cf605
commit 3672a5e421
+6 -1
View File
@@ -17,7 +17,12 @@ module.exports = {
} )
try {
apolloHelper( `${ctx.operation.operation} ${ctx.operation.selectionSet.selections[0].name.value}` )
console.log( ctx.operation.operation )
console.log( ctx.operation.selectionSet[0] )
// Filter out subscription ops
if ( !ctx.operation.operation.toLowerCase().includes( 'subscription' ) ) {
apolloHelper( `${ctx.operation.operation} ${ctx.operation.selectionSet.selections[0].name.value}` )
}
} catch ( e ) {
Sentry.captureException( e )
}