on-internet
← Community

Retrieve property of map object with arrow function

Stack Overflow ·

My map includes an arrow function which I can't access one of its properties/values of: Map(1) { '<id>' => User { id: '<id>', bot: false, system: false, flags: UserFlagsBitField { bitfield: 0 }, username: 'someUserName', globalName: 'someGlobalUsername', discriminator: '0', avatar: '<numbers>', banner: null, accentColor: null, avatarDecoration: null, avatarDecorationData: null, collectibles: null, primaryGuild: null } } Both <id>s are always the same. This is a discord.js result after fetch(). I need to access that map's username value. I've tried let someVar = thisVar.username; and maps.get()

Comments

Sign in or sign up to comment and upvote.

No comments yet.