Skip to content
This repository was archived by the owner on Aug 21, 2024. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,7 @@ const ProjectTable = ({ className }: Props) => {
query: {
allowed: true,
$limit: 100,
action: 'admin',
$sort: {
name: 1
}
Expand Down
2 changes: 2 additions & 0 deletions packages/engine/src/schemas/projects/project.schema.ts
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,7 @@ export const projectQuerySchema = Type.Intersect(
// Add additional query properties here
Type.Object(
{
action: Type.Optional(Type.String()),
sourceURL: Type.Optional(Type.String()),
destinationURL: Type.Optional(Type.String()),
existingProject: Type.Optional(Type.Boolean()),
Expand All @@ -132,6 +133,7 @@ export const projectQuerySchema = Type.Intersect(
{ additionalProperties: false }
)
],
// Add additional query properties here
{ additionalProperties: false }
)
export interface ProjectQuery extends Static<typeof projectQuerySchema> {}
Expand Down
4 changes: 2 additions & 2 deletions packages/server-core/src/projects/project/project.hooks.ts
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ All portions of the code written by the Ethereal Engine team are Copyright © 20
Ethereal Engine. All Rights Reserved.
*/
import { hooks as schemaHooks } from '@feathersjs/schema'
import { iff, isProvider } from 'feathers-hooks-common'
import { discardQuery, iff, isProvider } from 'feathers-hooks-common'

import { projectPermissionPath } from '@etherealengine/engine/src/schemas/projects/project-permission.schema'
import {
Expand Down Expand Up @@ -551,7 +551,7 @@ export default createSkippableHooks(

before: {
all: [() => schemaHooks.validateQuery(projectQueryValidator), schemaHooks.resolveQuery(projectQueryResolver)],
find: [enableClientPagination(), ensurePushStatus, addLimitToParams],
find: [enableClientPagination(), discardQuery('action'), ensurePushStatus, addLimitToParams],
get: [],
create: [
iff(isProvider('external'), verifyScope('editor', 'write')),
Expand Down