Config.js twitch.configuration.broadcaster undefined

You ran your .set too soon

You need to wait for onAuthorised before you can set.

This normally is not an issue if you do a .set in response to a streamer doing an action such as hitting a submit button.

So, move the updateConfig() from the end of the JS to inside the onAuthorized as a minumum.

twitch.onAuthorized((auth) => {
  token = auth.token;
  userId = auth.userId;

  updateConfig() 
});