Only add publish sidebar xblockinfo when needed.