code: function nameOfCommand(cmd) {
    if (!cmd) return "no command!";
    if (Array.isArray(cmd)) return nameOfCommand(cmd[0]);
    if (typeof cmd === "string") return cmd;
    if (cmd.name) return cmd.name;
    if (cmd.command) return cmd.command;
    return "unknown command, no name";
  }
docs: -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-