chore(server): auth IoC 4 - getAllAppsAuthorizedByUserFactory (#3019)

* chore(server): auth IoC 3 - getAllAppsCreatedByUserFactory

* minor fix

* chore(server): auth IoC 4 - getAllAppsAuthorizedByUserFactory

---------

Co-authored-by: Gergő Jedlicska <gergo@jedlicska.com>
This commit is contained in:
Kristaps Fabians Geikins
2024-09-19 10:22:12 +03:00
committed by GitHub
parent 40cc8caa6f
commit 860ebed68a
4 changed files with 32 additions and 31 deletions
@@ -1,6 +1,5 @@
const { ForbiddenError } = require('@/modules/shared/errors')
const {
getAllAppsAuthorizedByUser,
createApp,
updateApp,
deleteApp,
@@ -10,13 +9,15 @@ const { Roles } = require('@speckle/shared')
const {
getAppFactory,
getAllPublicAppsFactory,
getAllAppsCreatedByUserFactory
getAllAppsCreatedByUserFactory,
getAllAppsAuthorizedByUserFactory
} = require('@/modules/auth/repositories/apps')
const { db } = require('@/db/knex')
const getApp = getAppFactory({ db })
const getAllPublicApps = getAllPublicAppsFactory({ db })
const getAllAppsCreatedByUser = getAllAppsCreatedByUserFactory({ db })
const getAllAppsAuthorizedByUser = getAllAppsAuthorizedByUserFactory({ db })
module.exports = {
Query: {