Throw exception in `WCF::__call()` for undefined methods
authorMatthias Schmidt <gravatronics@live.com>
Tue, 18 Jun 2019 18:13:04 +0000 (20:13 +0200)
committerMatthias Schmidt <gravatronics@live.com>
Tue, 18 Jun 2019 18:13:04 +0000 (20:13 +0200)
wcfsetup/install/files/lib/system/WCF.class.php

index 16d26a9071bcf0f87f92aadcc31379e72cfc37d4..bf3fb73ba14881f4df04d2dc3b6993380d2c3137 100644 (file)
@@ -807,7 +807,7 @@ class WCF {
                        return self::__callStatic($name, $arguments);
                }
                
-               return $this->$name($arguments);
+               throw new \BadMethodCallException("Call to undefined method WCF::{$name}().");
        }
        
        /**