def GET_duplicates(self, article, num, after, reverse, count): links = link_duplicates(article) builder = IDBuilder( [link._fullname for link in links], num=num, after=after, reverse=reverse, count=count, skip=False ) listing = LinkListing(builder).listing() res = LinkInfoPage( link=article, comment=None, duplicates=links, content=listing, subtitle=_("other discussions") ).render() return res
def GET_duplicates(self, article, num, after, reverse, count): if not can_view_link_comments(article): abort(403, "forbidden") links = link_duplicates(article) links.sort(key=attrgetter("num_comments"), reverse=True) builder = IDBuilder( [link._fullname for link in links], num=num, after=after, reverse=reverse, count=count, skip=False ) listing = LinkListing(builder).listing() res = LinkInfoPage( link=article, comment=None, duplicates=links, content=listing, subtitle=_("other discussions") ).render() return res
def GET_duplicates(self, article, num, after, reverse, count): if not can_view_link_comments(article): abort(403, 'forbidden') links = link_duplicates(article) builder = IDBuilder([ link._fullname for link in links ], num = num, after = after, reverse = reverse, count = count, skip = False) listing = LinkListing(builder).listing() res = LinkInfoPage(link = article, comment = None, duplicates = links, content = listing, subtitle = _('other discussions')).render() return res