diff options
| author | Wes Bos <wesbos@gmail.com> | 2018-01-30 12:41:01 -0500 |
|---|---|---|
| committer | Wes Bos <wesbos@gmail.com> | 2018-01-30 12:41:01 -0500 |
| commit | cd0b07b3adb36fb5ec098f9e511ab45d774fee7b (patch) | |
| tree | a203e5010219ccea1acc6bbd2c0a4bcfa0a78615 /backend/src/resolvers/AuthPayload.js | |
| parent | 0a1648bf47490b312169c531aeb51ef4725e8d2e (diff) | |
Move to Prisma Backend
Diffstat (limited to 'backend/src/resolvers/AuthPayload.js')
| -rw-r--r-- | backend/src/resolvers/AuthPayload.js | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/backend/src/resolvers/AuthPayload.js b/backend/src/resolvers/AuthPayload.js new file mode 100644 index 0000000..f5945b7 --- /dev/null +++ b/backend/src/resolvers/AuthPayload.js @@ -0,0 +1,7 @@ +const { Context } = require('../utils'); + +const AuthPayload = { + user: async ({ user: { id } }, args, ctx, info) => ctx.db.query.user({ where: { id } }, info), +}; + +module.exports = AuthPayload; |
