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

🗜 Set db soft limits #9225

Merged
merged 3 commits into from
Nov 9, 2017
Merged

🗜 Set db soft limits #9225

merged 3 commits into from
Nov 9, 2017

Commits on Nov 9, 2017

  1. 🗜 Set db soft limits

    refs TryGhost#8143
    
    Sets soft limits for certain db fields:
    - `posts`:
    	- `title`: 255 chars (current hard limit: 2,000 chars)
    	- `meta_title`: 300 chars (current hard limit: 2,000 chars)
    	- `meta_description`: 500 chars (current hard limit: 2,000 chars)
    - `users`:
    	- `bio`: 200 chars (current hard limit: 65,535 chars)
    	- `location`: 150 chars (current hard limit: 65,535 chars)
    	- `meta_description`: 500 chars (current hard limit: 2,000 chars)
    	- `meta_title`: 300 chars (current hard limit: 2,000 chars)
    - `tags`:
    	- `description`: 500 chars (current hard limit: 65,535 chars)
    	- `meta_title`: 300 chars (current hard limit: 2,000 chars)
    	- `meta_description`: 500 chars (current hard limit: 2,000 chars)
    aileen committed Nov 9, 2017
    Configuration menu
    Copy the full SHA
    31cce3e View commit details
    Browse the repository at this point in the history
  2. Specific error message for isLength validator

    - Added a specific error message in `validate` fn for `isLength` method.
    - `validate` will take the `tableName` value as optional argument to provide a user friendly error message when exceeding db soft limits
    - added more tests for importer
    aileen committed Nov 9, 2017
    Configuration menu
    Copy the full SHA
    1b4cbe9 View commit details
    Browse the repository at this point in the history
  3. simplify logic for translating isLength for soft limits

    - dynamic translation key reading
    - you can define a custom translation for each validator
    kirrg001 committed Nov 9, 2017
    Configuration menu
    Copy the full SHA
    559f422 View commit details
    Browse the repository at this point in the history