add validation to model

This commit is contained in:
abcsun
2016-05-05 11:41:14 +08:00
parent f4ef2b0325
commit 22ea2d87e0
17 changed files with 987 additions and 60 deletions

View File

@@ -198,7 +198,7 @@ class FakeApi
if (strlen($password) > 64) {
throw new \InvalidArgumentException('invalid length for "$password" when calling FakeApi.testEndpointParameters, must be smaller than or equal to 64.');
}
if (strlen($password) > 10) {
if (strlen($password) < 10) {
throw new \InvalidArgumentException('invalid length for "$password" when calling FakeApi.testEndpointParameters, must be bigger than or equal to 10.');
}