From 7c56ff62990b690bc1031e27b4e95eb8fc9fc721 Mon Sep 17 00:00:00 2001 From: =?utf8?q?David=20=E2=80=98Bombe=E2=80=99=20Roden?= Date: Wed, 24 Nov 2010 11:16:33 +0100 Subject: [PATCH] Return the post element if its containing post element is requested. --- src/main/resources/static/javascript/sone.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/resources/static/javascript/sone.js b/src/main/resources/static/javascript/sone.js index 149520f..4277d9a 100644 --- a/src/main/resources/static/javascript/sone.js +++ b/src/main/resources/static/javascript/sone.js @@ -301,7 +301,7 @@ function getSoneId(element) { } function getPostElement(element) { - return $(element).parents(".post"); + return $(element).hasClass("post") ? $(element) : $(element).parents(".post"); } function getPostId(element) { -- 2.7.4