K
K
khodos_dmitry2020-06-02 18:19:36
PHP
khodos_dmitry, 2020-06-02 18:19:36

Why is InvalidArgumentException not being caught?

There is this code:

try {
$res = $func(...$this->atts_arr);
} catch (\BadFunctionCallException $e) {
} catch (\InvalidArgumentException $e) {
} catch (\Exception $e) {
}

But the InvalidArgumentException error still occurs. Why can this be?

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question