[core] Fix ignoring of whitespace in command prefixes.