geminilabs

Untitled

Mar 5th, 2021 (edited)
235
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. add_filter('site-reviews/review-form/fields', function ($fields) {
  2.     if (464591 == glsr_get($fields, 'form.value')) {
  3.         if ('textarea' === glsr_get($fields, 'content.type')) {
  4.             $fields = glsr_set($fields, 'content.minlength', 15);
  5.         }
  6.         if ('text' === glsr_get($fields, 'title.type')) {
  7.             $fields = glsr_set($fields, 'title.minlength', 10);
  8.         }
  9.     }
  10.     return $fields;
  11. }, 20);
RAW Paste Data Copied