chore: allows for custom endpoints

This commit is contained in:
Jarrod Flesch
2023-12-22 13:18:45 -05:00
parent b1b318e282
commit a267aad709
14 changed files with 227 additions and 162 deletions

View File

@@ -1,8 +1,7 @@
/* eslint-disable no-restricted-syntax */
/* eslint-disable no-await-in-loop */
import type { FilterQuery } from 'mongoose'
import type { Payload } from 'payload'
import type { Operator, Where } from 'payload/types'
import type { Operator, PayloadT, Where } from 'payload/types'
import type { Field } from 'payload/types'
import deepmerge from 'deepmerge'
@@ -24,7 +23,7 @@ export async function parseParams({
fields: Field[]
globalSlug?: string
locale: string
payload: Payload
payload: PayloadT
where: Where
}): Promise<Record<string, unknown>> {
let result = {} as FilterQuery<any>