Skip to content

Commit 812882d

Browse files
committed
removing pattern check from valid func
1 parent e0bb608 commit 812882d

File tree

1 file changed

+0
-15
lines changed

1 file changed

+0
-15
lines changed

generator/cybersource-php-template/model_generic.mustache

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -156,14 +156,6 @@ class {{classname}} {{#parentSchema}}extends {{{parent}}} {{/parentSchema}}imple
156156

157157
{{/isContainer}}
158158
{{/isEnum}}
159-
{{#hasValidation}}
160-
{{#pattern}}
161-
if ({{^required}}!is_null($this->container['{{name}}']) && {{/required}}!preg_match("{{{pattern}}}", $this->container['{{name}}'])) {
162-
$invalid_properties[] = "invalid value for '{{name}}', must be conform to the pattern {{{pattern}}}.";
163-
}
164-
165-
{{/pattern}}
166-
{{/hasValidation}}
167159
{{/vars}}
168160
return $invalid_properties;
169161
}
@@ -196,13 +188,6 @@ class {{classname}} {{#parentSchema}}extends {{{parent}}} {{/parentSchema}}imple
196188
}
197189
{{/isContainer}}
198190
{{/isEnum}}
199-
{{#hasValidation}}
200-
{{#pattern}}
201-
if (!preg_match("{{{pattern}}}", $this->container['{{name}}'])) {
202-
return false;
203-
}
204-
{{/pattern}}
205-
{{/hasValidation}}
206191
{{/vars}}
207192
return true;
208193
}

0 commit comments

Comments
 (0)