Snaterlicious added a subscriber: Snaterlicious.
Snaterlicious added a comment.

I suppose it was not possible in the past (probably before implementing the JS 
data model), but it would be better practice to retrieve the `Reference` 
objects from the Statement object, instead of gathering it from the 
`statementview` widget.
Changes to apply to the AuthorityControl gadget:
Change line `references = statementview.getReferences(),` to `referenceList = 
statement.getReferences(),`
and instead of a `for` loop, the `ReferenceList` object may be looped like in 
the following:

  referenceList.each( function() {
    this.getSnaks().each( function ( j, snak ) {
      [...]
    } );
  } );

That should do it.


TASK DETAIL
  https://phabricator.wikimedia.org/T86155

REPLY HANDLER ACTIONS
  Reply to comment or attach files, or !close, !claim, !unsubscribe or !assign 
<username>.

EMAIL PREFERENCES
  https://phabricator.wikimedia.org/settings/panel/emailpreferences/

To: Snaterlicious
Cc: Aklapper, aude, Tobi_WMDE_SW, Snaterlicious, Wikidata-bugs



_______________________________________________
Wikidata-bugs mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/wikidata-bugs

Reply via email to