hide code button fixes after refactor