Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The meta-data is invalid or is corrupt problem. #6

Open
zikezhang opened this issue Dec 18, 2015 · 3 comments
Open

The meta-data is invalid or is corrupt problem. #6

zikezhang opened this issue Dec 18, 2015 · 3 comments

Comments

@zikezhang
Copy link
Contributor

Hi , May I know how did you work it out ?

https://forum.phalconphp.com/discussion/7335/phalcon-203-the-metadata-is-invalid-or-is-corrupt

@nguyenducduy
Copy link
Owner

it problem occured when running out of phalcon version updated, i was update source for lastest version.

@zikezhang
Copy link
Contributor Author

Yes, I used the latest version of Phalcon, but this problem is still occured.

@nguyenducduy
Copy link
Owner

@@ it occured because i did not defined default value of meta data annotations, add this code to fix it.

/Files AnnotationsMetaDataInitializer.php/

public function getMetaData(ModelInterface $model, DiInterface $di)
{
...
// Default values for columns
PhalconMetadata::MODELS_DEFAULT_VALUES => [],

        // Fields that allow empty strings
        PhalconMetadata::MODELS_EMPTY_STRING_VALUES => []

}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants