title: Sequelize : How to map a custom attribute in a pivot table
body: <p>I've got this pivot table, which represents a many to many relationship with the models Person and Movie.</p>
  
  <p><a href="https://i.stack.imgur.com/Sjx3D.png" rel="noreferrer"><img src="https://i.stack.imgur.com/Sjx3D.png" alt="Pivot table schema"></a></p>
  
  <p>The thing is I want to get the role when I call the movies that get the persons associated. I tried this but it doesn't show the role :</p>
  
  <pre><code>models.Movie.findAll({
      include: [{
          model: models.Person,
          as: 'persons',
          through: {attributes: ["role"]}
      }]
  }).then(function(movies) {
      res.json(movies);
  });
  </code></pre>
  
  <p>Do I have to specify something in the models for the <code>role</code> ?</p>