Skip to content

Commit

Permalink
onCompletion(): replace instanceof check with @var for consistency
Browse files Browse the repository at this point in the history
  • Loading branch information
Blackjack200 committed Dec 29, 2024
1 parent a8cddf2 commit 30ed339
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions src/network/mcpe/ProcessSkinTask.php
Original file line number Diff line number Diff line change
Expand Up @@ -59,10 +59,8 @@ public function onRun() : void{
}

public function onCompletion() : void{
/** @var Skin|null $result */
$result = $this->getResult();
if(!($result instanceof Skin)){
$result = null;
}
/** @var \Closure(?Skin $skin,?string $error) : void $callback */
$callback = $this->fetchLocal(self::KEY_ON_COMPLETION);
($callback)($result, $this->error);
Expand Down

0 comments on commit 30ed339

Please sign in to comment.