Skip to content
This repository has been archived by the owner on Feb 9, 2021. It is now read-only.

Commit

Permalink
Fixed #2619 BlockMetadataStore
Browse files Browse the repository at this point in the history
  • Loading branch information
shoghicp committed Feb 15, 2015
1 parent 116ede3 commit 8e56782
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/pocketmine/metadata/BlockMetadataStore.php
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ public function disambiguate(Metadatable $block, $metadataKey){
}

public function getMetadata($block, $metadataKey){
if($block instanceof Block){
if(!($block instanceof Block)){
throw new \InvalidArgumentException("Object must be a Block");
}
if($block->getLevel() === $this->owningLevel){
Expand All @@ -53,7 +53,7 @@ public function getMetadata($block, $metadataKey){
}

public function hasMetadata($block, $metadataKey){
if($block instanceof Block){
if(!($block instanceof Block)){
throw new \InvalidArgumentException("Object must be a Block");
}
if($block->getLevel() === $this->owningLevel){
Expand All @@ -64,7 +64,7 @@ public function hasMetadata($block, $metadataKey){
}

public function removeMetadata($block, $metadataKey, Plugin $owningPlugin){
if($block instanceof Block){
if(!($block instanceof Block)){
throw new \InvalidArgumentException("Object must be a Block");
}
if($block->getLevel() === $this->owningLevel){
Expand All @@ -75,7 +75,7 @@ public function removeMetadata($block, $metadataKey, Plugin $owningPlugin){
}

public function setMetadata($block, $metadataKey, MetadataValue $newMetadatavalue){
if($block instanceof Block){
if(!($block instanceof Block)){
throw new \InvalidArgumentException("Object must be a Block");
}
if($block->getLevel() === $this->owningLevel){
Expand Down

0 comments on commit 8e56782

Please sign in to comment.