[Console Dialog Helper] Fix logic of code example
Merge pull request #3105 from bicpi/fix_code_example_logic

[Console Dialog Helper] Fix logic of code example