Skip to content

Commit

Permalink
Requested Changes
Browse files Browse the repository at this point in the history
  • Loading branch information
TheAbsolutionism committed Sep 29, 2024
1 parent 90db1bd commit a2f7b75
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
3 changes: 2 additions & 1 deletion src/main/java/ch/njol/skript/effects/EffBlockUpdate.java
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,8 @@ public boolean init(Expression<?>[] exprs, int matchedPattern, Kleenean isDelaye
@Override
protected void execute(Event event) {
BlockData data = this.blockData.getSingle(event);
assert data != null;
if (data == null)
return;
for (Block block : this.blocks.getArray(event)) {
block.setBlockData(data, this.physics);
}
Expand Down
4 changes: 2 additions & 2 deletions src/test/skript/tests/syntaxes/effects/EffBlockUpdate.sk
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,6 @@ test "block update":
set {_blocks::*} to blocks in radius 2 of block at {_loc}

update blocks at {_blocks::*} as sand without physics updates
assert blocks at {_blocks::*} is sand with "1 or more block did not update with or without physics"
assert blocks at {_blocks::*} is sand with "1 or more blocks did not update with or without physics"
update blocks at {_blocks::*} as air without physics updates
assert blocks at {_blocks::*} is air with "1 or more block did not update to air"
assert blocks at {_blocks::*} is air with "1 or more blocks did not update to air"

0 comments on commit a2f7b75

Please sign in to comment.