mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-09-09 03:06:55 +00:00
InventoryTransaction: sync inventories before throwing validation exception to caller
fixes #3226 really the transaction shouldn't be handling inventory sync at all, but that's a job for another commit.
This commit is contained in:
@ -293,7 +293,12 @@ class InventoryTransaction{
|
||||
|
||||
$this->shuffleActions();
|
||||
|
||||
$this->validate();
|
||||
try{
|
||||
$this->validate();
|
||||
}catch(TransactionValidationException $e){
|
||||
$this->sendInventories();
|
||||
throw $e;
|
||||
}
|
||||
|
||||
if(!$this->callExecuteEvent()){
|
||||
$this->sendInventories();
|
||||
|
Reference in New Issue
Block a user