From 0d311432e78fb4f43fcb2bf3288e0f58a655c7b1 Mon Sep 17 00:00:00 2001 From: ymao2 Date: Tue, 10 Oct 2023 17:56:41 +0100 Subject: [PATCH] DPAT-1711 Removed the redundant token field --- controlpanel/api/auth0_conns/auth0_nomis/fetchUserProfile.js | 1 - tests/api/fixtures/nomis_body.json | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/controlpanel/api/auth0_conns/auth0_nomis/fetchUserProfile.js b/controlpanel/api/auth0_conns/auth0_nomis/fetchUserProfile.js index 6813de5db..edd73a7ca 100644 --- a/controlpanel/api/auth0_conns/auth0_nomis/fetchUserProfile.js +++ b/controlpanel/api/auth0_conns/auth0_nomis/fetchUserProfile.js @@ -7,7 +7,6 @@ function fetchUserProfile(accessToken, context, callback) { nickname: context.name, name: context.name, username: context.user_name, - _deliusAccessToken: accessToken, _accessToken: accessToken, email: context.user_name + "+" + context.user_id + "@" + context.auth_source, }; diff --git a/tests/api/fixtures/nomis_body.json b/tests/api/fixtures/nomis_body.json index fca244dda..084d06dbd 100644 --- a/tests/api/fixtures/nomis_body.json +++ b/tests/api/fixtures/nomis_body.json @@ -1,7 +1,7 @@ { "options": { "scripts": { - "fetchUserProfile": "function fetchUserProfile(accessToken, context, callback) {\n // The email is only for auth0 usage purpose, not the actual email of login user\n const profile = {\n sub: context.sub,\n user_id: context.user_id,\n auth_source: context.auth_source,\n nickname: context.name,\n name: context.name,\n username: context.user_name,\n _deliusAccessToken: accessToken,\n _accessToken: accessToken,\n email: context.user_name + \"+\" + context.user_id + \"@\" + context.auth_source,\n };\n callback(null, profile);\n}\n" + "fetchUserProfile": "function fetchUserProfile(accessToken, context, callback) {\n // The email is only for auth0 usage purpose, not the actual email of login user\n const profile = {\n sub: context.sub,\n user_id: context.user_id,\n auth_source: context.auth_source,\n nickname: context.name,\n name: context.name,\n username: context.user_name,\n _accessToken: accessToken,\n email: context.user_name + \"+\" + context.user_id + \"@\" + context.auth_source,\n };\n callback(null, profile);\n}" }, "client_id": "test_nomis_connection_id", "client_secret": "WNXFkM3FCTXJhUWs0Q1NwcKFu",