Fixing an error

This commit is contained in:
Ad5001 2017-02-20 17:56:21 +01:00
parent a2dba5e17f
commit e9befa237e
1 changed files with 5 additions and 1 deletions

View File

@ -282,7 +282,11 @@ class Main extends PluginBase implements Listener {
@return bool
*/
public function isCompatible() : bool {
return class_exists("pocketmine\\tile\\Hopper") && class_exists("pocketmine\\block\\SlimeBlock") && class_exists("pocketmine\\item\\Lever");
try {
return @class_exists("pocketmine\\tile\\Hopper") && @class_exists("pocketmine\\block\\SlimeBlock")/* && @class_exists("pocketmine\\item\\Lever")*/;
} catch (\Exception $e) {
return false;
}
}