Here's the deal: I'm trying to get data from a variable in a JSON file by name with a different variable. Basically, I want to access MusicJSON.Bands.M83.length by replacing the "M83" with "Bands", else, I'd have to add every single variable in the JSON file into my code, which defeats the purpose to me. Here's my code:
for(i = 0; i < MusicJSON.Bands.Names.length; i++) {
var Band = MusicJSON.Bands.Names[i]
NextMessage += "\n " + Band + MusicJSON.Bands.length + " songs"; // Right here
}
NextMessage += "**";
message.channel.send(`Here's a list of bands available on this server: \n ${NextMessage}`)