diff --git a/bookmarklet.js b/bookmarklet.js index 47ce7f0..4b34de1 100644 --- a/bookmarklet.js +++ b/bookmarklet.js @@ -16,7 +16,7 @@ function getLastTweet() { var author = window.location.pathname.split('/')[1]; - var xp = "//a[contains(@href, '"+author+"/status')]"; + var xp = "//a[contains(@href, '"+author+"/status') and not(contains(@href, 'photo')) and not(contains(@href, 'like'))]"; return getLastXPath(xp).pathname; } diff --git a/bookmarklet.min.js b/bookmarklet.min.js index ea7f280..5307ef0 100644 --- a/bookmarklet.min.js +++ b/bookmarklet.min.js @@ -1 +1 @@ -k="http://localhost:8080/thread"+b(),window.open(k,"_blank");function b(){return function(t){for(var n=document.evaluate(t,document,null,XPathResult.ORDERED_NODE_ITERATOR_TYPE,null),a=n.iterateNext(),e=a;null!=a&&null!=(a=n.iterateNext());)e=a;return e}("//a[contains(@href, '"+window.location.pathname.split("/")[1]+"/status')]").pathname}var k; +javascript:k="http://localhost:8080/thread"+b(),window.open(k,"_blank");function b(){return function(t){for(var n=document.evaluate(t,document,null,XPathResult.ORDERED_NODE_ITERATOR_TYPE,null),a=n.iterateNext(),e=a;null!=a&&null!=(a=n.iterateNext());)e=a;return e}("//a[contains(@href, '"+window.location.pathname.split("/")[1]+"/status') and not(contains(@href, 'photo')) and not(contains(@href, 'like'))]").pathname}var k; diff --git a/tweetlog.nimble b/tweetlog.nimble index e8bd4ef..1e656ae 100644 --- a/tweetlog.nimble +++ b/tweetlog.nimble @@ -15,4 +15,4 @@ requires "https://github.com/pragmagic/karax" task bookmark, "Builds the minified bookmarklet": "echo -n 'javascript:' > ./bookmarklet.min.js".exec - "uglifyjs --mangle --compress toplevel,sequences=false bookmarklet.js > ./bookmarklet.min.js".exec + "uglifyjs --mangle --compress toplevel,sequences=false bookmarklet.js >> ./bookmarklet.min.js".exec