diff options
author | Matthias Benkard <code@mail.matthias.benkard.de> | 2009-10-08 12:01:31 +0200 |
---|---|---|
committer | Matthias Benkard <code@mail.matthias.benkard.de> | 2009-10-08 12:01:31 +0200 |
commit | 17fc34ad3813632aa995a33354cd1afa77f7c68f (patch) | |
tree | 5c2163be9617b7672c60ebfd9cbb7df29bbcacc9 | |
parent | 58c5caa008c6a52709cf36f0ecec3b0e55158583 (diff) |
Don't record trackbacks that do not specify a source URI.
Ignore-this: 32405052f2ec95ca977b98e52503ae4b
darcs-hash:268cfba3e3e476425789ac960ab3e47e5ec050c4
-rw-r--r-- | main.lisp | 24 |
1 files changed, 12 insertions, 12 deletions
@@ -206,20 +206,20 @@ (cond ((getf *query* :url) (push trackback (trackbacks-about entry)) + (with-slots (spam-p) trackback + (setq spam-p (detect-spam trackback + :referrer (gethash "HTTP_REFERER" *http-env*)))) + (update-records-from-instance trackback) + (update-records-from-instance entry) + (unless (spamp trackback) + (update-records 'journal_trackback + :where [= [slot-value 'journal-trackback 'id] (id-of trackback)] + :av-pairs `((spam_p nil)))) + (when (eq *site* :nfs.net) + (mail-trackback *notification-email* trackback entry)) (format t "<?xml version=\"1.0\" encoding=\"utf-8\"?>~&<response>~&<error>0</error>~&</response>")) (t - (format t "<?xml version=\"1.0\" encoding=\"utf-8\"?>~&<response>~&<error>1</error>~&<message>No URI was provided.</message>~&</response>"))) - (with-slots (spam-p) trackback - (setq spam-p (detect-spam trackback - :referrer (gethash "HTTP_REFERER" *http-env*)))) - (update-records-from-instance trackback) - (update-records-from-instance entry) - (unless (spamp trackback) - (update-records 'journal_trackback - :where [= [slot-value 'journal-trackback 'id] (id-of trackback)] - :av-pairs `((spam_p nil)))) - (when (eq *site* :nfs.net) - (mail-trackback *notification-email* trackback entry))))) + (format t "<?xml version=\"1.0\" encoding=\"utf-8\"?>~&<response>~&<error>1</error>~&<message>No URI was provided.</message>~&</response>")))))) (:view-atom-feed (show-atom-feed)) (:view-comment-feed (show-comment-feed)) (:view-debugging-page (show-debugging-page)) |