diff --git a/caption_filter.module b/caption_filter.module index 2ca7d0d..4e7188a 100644 --- a/caption_filter.module +++ b/caption_filter.module @@ -114,9 +114,12 @@ function _caption_filter_get_width($item) { unset($src_result, $width_result, $internal_result, $tag, $item); // We need to append the 'px' to any numeric widths. - if (is_numeric($width)) { + if (isset($width) && is_numeric($width)) { $width = $width . 'px'; } + else { + $width = NULL; + } return $width; }