mirror of
https://github.com/TotalFreedomMC/TF-ProjectKorra.git
synced 2024-12-23 00:15:05 +00:00
Fix NPE in blocksource
This commit is contained in:
parent
eaf183f8c4
commit
d930c78d16
1 changed files with 6 additions and 3 deletions
|
@ -156,10 +156,13 @@ public class BlockSource {
|
|||
*/
|
||||
public static Block getSourceBlock(Player player, double range, BlockSourceType sourceType, ClickType clickType) {
|
||||
BlockSourceInformation info = getValidBlockSourceInformation(player, range, sourceType, clickType);
|
||||
if (info != null) {
|
||||
if (TempBlock.isTempBlock(info.getBlock())) {
|
||||
return null;
|
||||
}
|
||||
return info != null ? info.getBlock() : null;
|
||||
return info.getBlock();
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Reference in a new issue