Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Fixes warning in field type "datepicker"

  • Loading branch information...
commit fc15a5b779c11e0514db1f9918790ef07c4f4dee 1 parent f251ead
@PhilippSchreiber authored
Showing with 1 addition and 1 deletion.
  1. +1 −1  custom_metadata.php
View
2  custom_metadata.php
@@ -955,7 +955,7 @@ function _display_metadata_field( $field_slug, $field, $object_type, $object_id
<?php break; ?>
<?php case 'datepicker': ?>
- <input type="text" name="<?php echo $field_id; ?>" value="<?php echo (isset($v)) ? date('m/d/Y', $v) : ''; ?>" <?php echo $readonly_str ?>/>
+ <input type="text" name="<?php echo $field_id; ?>" value="<?php echo (isset($v) && trim($v) != '') ? date('m/d/Y', $v) : ''; ?>" <?php echo $readonly_str ?>/>
<?php break; ?>
<?php case 'wysiwyg': ?>
Please sign in to comment.
Something went wrong with that request. Please try again.