MCPcopy Create free account
hub / github.com/zenstackhq/zenstack / isValidModel

Method isValidModel

packages/server/src/api/rpc/index.ts:380–382  ·  view source on GitHub ↗
(client: ClientContract<Schema>, model: string)

Source from the content-addressed store, hash-verified

378 }
379
380 private isValidModel(client: ClientContract<Schema>, model: string) {
381 return Object.keys(client.$schema.models).some((m) => lowerCaseFirst(m) === lowerCaseFirst(model));
382 }
383
384 private makeBadInputErrorResponse(message: string) {
385 const resp = {

Callers 2

handleRequestMethod · 0.95
handleTransactionMethod · 0.95

Calls 1

lowerCaseFirstFunction · 0.90

Tested by

no test coverage detected