[Concept] [PATCH v2 13/16] console: Refactor handling of the result in on_console()