Handle event validator parsing
This commit is contained in:
parent
99262e28fe
commit
39233cfe1c
2 changed files with 6 additions and 3 deletions
|
@ -189,6 +189,7 @@ class Builder
|
||||||
|
|
||||||
switch ((!empty($validator)) ? \get_class($validator) : '') {
|
switch ((!empty($validator)) ? \get_class($validator) : '') {
|
||||||
case 'Appwrite\Auth\Validator\Password':
|
case 'Appwrite\Auth\Validator\Password':
|
||||||
|
case 'Appwrite\Event\Validator\Event':
|
||||||
case 'Appwrite\Network\Validator\CNAME':
|
case 'Appwrite\Network\Validator\CNAME':
|
||||||
case 'Appwrite\Network\Validator\Domain':
|
case 'Appwrite\Network\Validator\Domain':
|
||||||
case 'Appwrite\Network\Validator\Email':
|
case 'Appwrite\Network\Validator\Email':
|
||||||
|
@ -235,9 +236,11 @@ class Builder
|
||||||
break;
|
break;
|
||||||
case 'Utopia\Validator\Assoc':
|
case 'Utopia\Validator\Assoc':
|
||||||
case 'Utopia\Validator\JSON':
|
case 'Utopia\Validator\JSON':
|
||||||
default:
|
|
||||||
$type = self::json();
|
$type = self::json();
|
||||||
break;
|
break;
|
||||||
|
default:
|
||||||
|
$type = Type::string();
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
if ($required) {
|
if ($required) {
|
||||||
|
|
|
@ -1066,7 +1066,7 @@ trait GraphQLBase
|
||||||
}
|
}
|
||||||
}';
|
}';
|
||||||
case self::$CREATE_FUNCTION:
|
case self::$CREATE_FUNCTION:
|
||||||
return 'mutation createFunction($functionId: String!, $name: String!, $execute: [String!]!, $runtime: String! $vars: Json, $events: [Json], $schedule: String, $timeout: Int) {
|
return 'mutation createFunction($functionId: String!, $name: String!, $execute: [String!]!, $runtime: String! $vars: Json, $events: [String], $schedule: String, $timeout: Int) {
|
||||||
functionsCreate(functionId: $functionId, name: $name, execute: $execute, runtime: $runtime, vars: $vars, events: $events, schedule: $schedule, timeout: $timeout) {
|
functionsCreate(functionId: $functionId, name: $name, execute: $execute, runtime: $runtime, vars: $vars, events: $events, schedule: $schedule, timeout: $timeout) {
|
||||||
_id
|
_id
|
||||||
name
|
name
|
||||||
|
@ -1075,7 +1075,7 @@ trait GraphQLBase
|
||||||
}
|
}
|
||||||
}';
|
}';
|
||||||
case self::$UPDATE_FUNCTION:
|
case self::$UPDATE_FUNCTION:
|
||||||
return 'mutation updateFunction($functionId: String!, $name: String!, $execute: [String!]!, $vars: Json, $events: [Json], $schedule: String, $timeout: Int) {
|
return 'mutation updateFunction($functionId: String!, $name: String!, $execute: [String!]!, $vars: Json, $events: [String], $schedule: String, $timeout: Int) {
|
||||||
functionsUpdate(functionId: $functionId, name: $name, execute: $execute, vars: $vars, events: $events, schedule: $schedule, timeout: $timeout) {
|
functionsUpdate(functionId: $functionId, name: $name, execute: $execute, vars: $vars, events: $events, schedule: $schedule, timeout: $timeout) {
|
||||||
_id
|
_id
|
||||||
name
|
name
|
||||||
|
|
Loading…
Reference in a new issue