Merge remote-tracking branch 'upstream/4.6' into 4.6-master-2015-08-06-19-31-58
[civicrm-core.git] / CRM / Core / BAO / PdfFormat.php
index 6f1fbced8408a51ec8a4f161f3965a6ffb5f6e9b..60b7739a4b3127b91125a7b1619cb68d0bc56515 100644 (file)
@@ -29,7 +29,7 @@
 /**
  *
  * @package CRM
- * @copyright CiviCRM LLC (c) 2004-2014
+ * @copyright CiviCRM LLC (c) 2004-2015
  * $Id$
  *
  */
@@ -306,7 +306,7 @@ class CRM_Core_BAO_PdfFormat extends CRM_Core_DAO_OptionValue {
       foreach (self::$optionValueFields as $name => $field) {
         if (!isset($values[$name])) {
           $values[$name] = $field['default'];
-          if ($field['metric']) {
+          if (!empty($field['metric'])) {
             $values[$name] = CRM_Utils_PDF_Utils::convertMetric($field['default'],
               self::$optionValueFields['metric']['default'],
               $values['metric'], 3