Skip to content

Commit 2329e12

Browse files
committed
Speed up getUser
1 parent c10cebd commit 2329e12

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/remotes/auth0/index.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -141,10 +141,10 @@ export default function createAuth0Schema(domain, clientId, clientSecret) {
141141
getUser: async (_, { where, fresh }, ctx) => {
142142
try {
143143
const fn = fresh ? findUsersUncached : findUsers;
144-
await updateUser(where, { scopes: ["write:users"] }, (prev) => {
145-
const user = sanitizeUser({ ...prev })
146-
return { ...user };
147-
});
144+
// await updateUser(where, { scopes: ["write:users"] }, (prev) => {
145+
// const user = sanitizeUser({ ...prev })
146+
// return { ...user };
147+
// });
148148
return (await fn(where, ctx))[0] || null
149149
} catch (ex) { return null; }
150150
},

0 commit comments

Comments
 (0)