Fixing bug in toggle block.