title: How to have a many to many relation that enforces uniqueness when I use an intermediate model?
body: <p>I use intermediate model for &quot;ManyToManyField using the through&quot;<br />
  Normally,If I don't use intermediate field, the m2m relation will be unique and can't have the duplicated data.</p>
  <p>After I use intermediate model. the relation between m2m can have same data. like this</p>
  <pre><code>|    |    ['0'] (
  |    |    |    addToProfile =&gt; Array (0)
  |    |    |    (
  |    |    |    )
  |    |    |    endDate =  NULL
  |    |    |    feedType =  &quot;N&quot;
  |    |    |    id =  1
  |    |    |    info =  &quot;Big Kuy No Fear&quot;
  |    |    |    likeMaker =&gt; Array (3)
  |    |    |    (
  |    |    |    |    ['0'] =  &quot;/api/v2/user/2/&quot;
  |    |    |    |    ['1'] =  &quot;/api/v2/user/2/&quot;
  |    |    |    |    ['2'] =  &quot;/api/v2/user/2/&quot;
  |    |    |    )
  |    |    |    like_count =  &quot;3&quot;
  </code></pre>
  <p>I am building a social network. So this is my feed object that has 3 <code>like_count</code>s . But the three of this like come from the same user &quot;/api/v2/user/2/&quot;</p>
  <p>I try to add &quot;unique=True&quot; attribute at m2m field but django come up with the error because It doesn't grant the permission to add the &quot;unique&quot; attribute to m2m field at first. Can anyone help me?</p>