refactor the fortune command.