discord-api-docs icon indicating copy to clipboard operation
discord-api-docs copied to clipboard

name_localizations at command level does not work for commands that have subcommands

Open MorningSleeper opened this issue 2 years ago • 0 comments

Description

When I add name_localizations for a command name that contains subcommands, the name entered for name_localizations does not make any of the subcommands appear. Works fine in commands without subcommands.

Steps to Reproduce

Used the following example JSON, set user account at Discord to language English, US and entered /lookup and it does not show /find or /lookup subcommands.

{
    "name": "find",
    "name_localizations": {
      "en-US": "lookup"
    },
    "description": "Find a symbol or company.",
    "options": [{
        "type": 1,
        "name": "symbol",
        "description": "Search for ticker symbol by company name.",
        "options": [{
          "type": 3,
          "name": "company",
          "description": "Enter a company name.",
          "required": true
        }]
      },
      {
        "type": 1,
        "name": "company",
        "description": "Search for company by ticker symbol.",
        "options": [{
          "type": 3,
          "name": "symbol",
          "description": "Enter a ticker symbol.",
          "required": true
        }]
      }
    ]
  }

Expected Behavior

When one enters the name defined in name_localizations, /lookup, I would expect it to show the two subcommands.

Current Behavior

When /lookup is entered it does not show /find or /lookup subcommands.

Screenshots/Videos

image

image

Client and System Information

Discord Desktop Stable 132311 (3bb6ec2) Windows 10 64-Bit (10.0.19044) Discord.js 13.6

MorningSleeper avatar Jun 22 '22 02:06 MorningSleeper