Converted EmptyBlocks function