Fix possible NPE in excludeBlocks refresh