Fixing console command history issues

Fixing an issue where the last character of a command was missing when viewing the history.

Fixing an issue where navigating the history was not showing the correct commands. (not in the proper order)