File tree Expand file tree Collapse file tree 1 file changed +14
-6
lines changed
Expand file tree Collapse file tree 1 file changed +14
-6
lines changed Original file line number Diff line number Diff line change @@ -216,9 +216,13 @@ function _PEAR() {
216216 public function __call ($ method , $ arguments )
217217 {
218218 if (!isset (self ::$ bivalentMethods [$ method ])) {
219- trigger_error (
220- 'Call to undefined method PEAR:: ' . $ method . '() ' , E_USER_ERROR
221- );
219+ if (PHP_VERSION_ID < 70000 ) {
220+ trigger_error (
221+ 'Call to undefined method PEAR:: ' . $ method . '() ' , E_USER_ERROR
222+ );
223+ } else {
224+ throw new Error ('Call to undefined method PEAR:: ' . $ method . '() ' );
225+ }
222226 }
223227 return call_user_func_array (
224228 array (__CLASS__ , '_ ' . $ method ),
@@ -229,9 +233,13 @@ public function __call($method, $arguments)
229233 public static function __callStatic ($ method , $ arguments )
230234 {
231235 if (!isset (self ::$ bivalentMethods [$ method ])) {
232- trigger_error (
233- 'Call to undefined method PEAR:: ' . $ method . '() ' , E_USER_ERROR
234- );
236+ if (PHP_VERSION_ID < 70000 ) {
237+ trigger_error (
238+ 'Call to undefined method PEAR:: ' . $ method . '() ' , E_USER_ERROR
239+ );
240+ } else {
241+ throw new Error ('Call to undefined method PEAR:: ' . $ method . '() ' );
242+ }
235243 }
236244 return call_user_func_array (
237245 array (__CLASS__ , '_ ' . $ method ),
You can’t perform that action at this time.
0 commit comments