##// END OF EJS Templates
Fixed reflinks to threads parsing
neko259 -
r313:0f161354 default
parent child Browse files
Show More
@@ -45,7 +45,7 b' class ReflinkPattern(Pattern):'
45 link = reverse(boards.views.thread, kwargs={'post_id': post.thread.id}) \
45 link = reverse(boards.views.thread, kwargs={'post_id': post.thread.id}) \
46 + '#' + post_id
46 + '#' + post_id
47 else:
47 else:
48 link = reverse(boards.views.thread, post_id=post_id)
48 link = reverse(boards.views.thread, kwargs={'post_id': post_id})
49
49
50 ref_element.set('href', link)
50 ref_element.set('href', link)
51 ref_element.text = m.group(2)
51 ref_element.text = m.group(2)
@@ -266,7 +266,7 b' def jump_to_post(request, post_id):'
266 post = get_object_or_404(Post, id=post_id)
266 post = get_object_or_404(Post, id=post_id)
267
267
268 if not post.thread:
268 if not post.thread:
269 return redirect(thread, post_id=post.id)
269 return redirect(thread, post_id=post.id)
270 else:
270 else:
271 return redirect(reverse(thread, kwargs={'post_id': post.thread.id})
271 return redirect(reverse(thread, kwargs={'post_id': post.thread.id})
272 + '#' + str(post.id))
272 + '#' + str(post.id))
General Comments 0
You need to be logged in to leave comments. Login now