Fix attempted assignment to rvalue.
Strip “unnecessary compatibility things” from `toggleCodeExpand`.