Remove read items from later and vice versa
This commit is contained in:
parent
f5a9184f89
commit
e1e3754e29
|
@ -74,6 +74,7 @@ sub redirect {
|
|||
print "Location: $item->{link}\n";
|
||||
print "\n";
|
||||
$dbh->do("insert into read(username, item_id) values(?, ?)", {}, $q->remote_user, $item_id);
|
||||
$dbh->do("delete from later where username=? and item_id=?", {}, $q->remote_user, $item_id);
|
||||
$mcd->delete(item_info_key($q->remote_user, $item->{feed_id}));
|
||||
exit(0);
|
||||
}
|
||||
|
@ -97,6 +98,7 @@ sub mark {
|
|||
print "Location: ", $q1->self_url, "\n";
|
||||
print "\n";
|
||||
$dbh->do("insert into read(username, item_id) values(?, ?)", {}, $q->remote_user, $item_id);
|
||||
$dbh->do("delete from later where username=? and item_id=?", {}, $q->remote_user, $item_id);
|
||||
$mcd->delete(item_info_key($q->remote_user, $item->{feed_id}));
|
||||
print_log("mark done");
|
||||
exit(0);
|
||||
|
@ -122,6 +124,7 @@ sub mark_later {
|
|||
print "Location: ", $q1->self_url, "\n";
|
||||
print "\n";
|
||||
$dbh->do("insert into later(username, item_id) values(?, ?)", {}, $q->remote_user, $item_id);
|
||||
$dbh->do("delete from read where username=? and item_id=?", {}, $q->remote_user, $item_id);
|
||||
$mcd->delete(item_info_key($q->remote_user, $item->{feed_id}));
|
||||
print_log("mark_later done");
|
||||
exit(0);
|
||||
|
|
Loading…
Reference in New Issue