de-duplication of received likes to prefer indie likes
When a Red Wind post receives a webmention of from an indie like, Red Wind should de-duplicate it with any likes of the silo copy of that Red Wind post, and vice versa, always preferring the indie like, and showing it as one like, not two.
E.g. real world example of a Red Wind post with an indie like:
- https://kylewm.com/2015/06/yes-https-is-more-work-to-support-than-http-so-let And the indie like post original which also contains (in-place POSSE) a like-of the tweet POSSE copy of the Red Wind post:
- http://tantek.com/2015/169/f1
There should be enough information there to de-dup that into displaying a single like on the Red Wind post.
Thank you for filing, though I'm still not convinced it's possible -- I don't see any fields in the two parsed results that can be correlated to tell that they are duplicates :confused:
Here's the information I have from Brid.gy
{
"items": [
{
"properties": {
"author": [
{
"properties": {
"name": [
"Tantek \u00c7elik"
],
"photo": [
"https://twitter.com/t/profile_image?size=original"
],
"url": [
"https://twitter.com/t"
]
},
"type": [
"h-card"
],
"value": "Tantek \u00c7elik"
}
],
"like": [
"https://twitter.com/kylewmahan/status/610521450290675713",
"https://kylewm.com/2015/06/yes-https-is-more-work-to-support-than-http-so-let"
],
"like-of": [
"https://twitter.com/kylewmahan/status/610521450290675713",
"https://kylewm.com/2015/06/yes-https-is-more-work-to-support-than-http-so-let"
],
"name": [
"likes this."
],
"uid": [
"tag:twitter.com,2013:610521450290675713_favorited_by_11628"
],
"url": [
"https://twitter.com/kylewmahan/status/610521450290675713"
]
},
"type": [
"h-entry",
"h-as-like"
]
}
],
"rel-urls": {},
"rels": {}
}
and from the original
{
"items": [
{
"properties": {
"author": [
{
"properties": {
"name": [
"Tantek \u00c7elik"
],
"photo": [
"http://tantek.com/logo.jpg"
],
"url": [
"http://tantek.com/"
]
},
"type": [
"h-card"
],
"value": ""
}
],
"content": [
{
"html": "likes \n<a class=\"u-like-of\" href=\"https://kylewm.com/2015/06/yes-https-is-more-work-to-support-than-http-so-let\">Kyle Mahan\u2019s note</a>\n (<a class=\"u-like-of\" href=\"https://twitter.com/kylewmahan/status/610521450290675713\">@</a>)",
"value": "likes \nKyle Mahan\u2019s note\n (@)"
}
],
"like-of": [
"https://kylewm.com/2015/06/yes-https-is-more-work-to-support-than-http-so-let",
"https://twitter.com/kylewmahan/status/610521450290675713"
],
"name": [
"likes \nKyle Mahan\u2019s note\n (@)"
],
"published": [
"2015-06-18T11:22:00-0700"
],
"uid": [
"http://tantek.com/2015/169/f1"
],
"updated": [
"2015-06-18T11:22:00-0700"
],
"url": [
"http://tantek.com/2015/169/f1"
]
},
"type": [
"h-entry",
"h-as-like"
]
}
],
"rel-urls": {
"http://tantek.com/": {
"rels": [
"author",
"home",
"author"
],
"text": "",
"title": "Tantek \u00c7elik"
},
"http://tantek.com/2015/168/f1": {
"rels": [
"prev"
],
"text": "\u2190",
"title": "View the previous (older) item in the stream."
},
"http://tantek.com/logo.jpg": {
"rels": [
"icon"
],
"text": ""
},
"http://webmention.io/tantek.com/webmention": {
"rels": [
"webmention"
],
"text": ""
}
},
"rels": {
"author": [
"http://tantek.com/",
"http://tantek.com/"
],
"home": [
"http://tantek.com/"
],
"icon": [
"http://tantek.com/logo.jpg"
],
"prev": [
"http://tantek.com/2015/168/f1"
],
"webmention": [
"http://webmention.io/tantek.com/webmention"
]
}
}
Hmm - looks like we may have to add another step:
- check the Bridgy like-of author URL to see if it has a rel=me link, e.g. in the above JSON it's https://twitter.com/t which has rel=me link to tantek.com. Then if you have already have a like-of from that author, with permalink on that domain, you should be able to de-dup the Bridgy one.