falkirks/RankUp

PurePerms Crash

Closed this issue · 6 comments

Error: Call to undefined method _64FF00\PurePerms\PurePerms::getUser()
File: /RankUp_v0.3.1.phar/src/rankup/permission/PurePerms
Line: 15
Type: E_ERROR

THIS CRASH WAS CAUSED BY A PLUGIN
BAD PLUGIN: RankUp v0.3.1

Code:
[6] class PurePerms extends BasePermissionManager{
[7] public function addToGroup(Player $player, $group){
[8] if(!$this->checkReady()) return false;
[9] $ppGroup = $this->getAPI()->getGroup($group);
[10] $this->getAPI()->getUser($player)->setGroup($ppGroup, null);
[11] return true;
[12] }
[13] public function getGroup(Player $player){
[14] if(!$this->checkReady()) return false;
[15] $user = $this->getAPI()->getUser($player);
[16] return $user->getGroup()->getName();
[17] }
[18]
[19] /**
[20] * getUsers() is not implemented in PurePerms. This method will NOT work.
[21] * @param $name
[22] * @return bool|void
[23] */
[24] public function getPlayersInGroup($name){
[25] if(!$this->checkReady()) return false;

Backtrace:
#0 (): pocketmine\Server->crashDump(boolean)

PocketMine-MP version: 1.6dev #43 [Protocol 34; API 1.13.0]
Git commit: 0000000000000000000000000000000000000000
uname -a: Linux flexcraft 2.6.32-042stab108.5 #1 SMP Wed Jun 17 20:20:17 MSK 2015 i686
PHP Version: 5.6.2
Zend version: 2.6.0
OS : Linux, linux
46 minutes ago EditDeleteReport+ QuoteReply

This should be fixed in 3ce9dbb

Still not fixed, "unknown error while performing this command"

[10:53:18] [Server thread/CRITICAL]: Unhandled exception executing command 'rankup' in rankup: strtolower() expects parameter 1 to be string, object given[10:53:18] [Server thread/WARNING]: InvalidArgumentException: "strtolower() expects parameter 1 to be string, object given" (E_WARNING) in "/phar_RankUp-master_Xk25BVDtGo3Y1p7.phar/src/rankup/rank/RankStore" at line 25

Atleast it doesn't crash the server

@goerick Thanks for testing it, I still haven't been able to. I have pushed a fix for the error you posted.

Ifera commented

This issue is fixed in the latest commits. Not occurring anymore. @falkirks this can be closed.