diff --git a/src/Html2Text.php b/src/Html2Text.php index 9f8a9d6..b5a85a7 100644 --- a/src/Html2Text.php +++ b/src/Html2Text.php @@ -705,7 +705,7 @@ private function getOptionsForElement($element) $element = strtolower($element); if (!array_key_exists($element, $this->options['elements'])) { - throw new \InvalidArgumentException("Element '$element' has no options"); + return null; } return $this->options['elements'][$element];