diff options
author | Yorhel <git@yorhel.nl> | 2009-10-24 15:18:34 +0200 |
---|---|---|
committer | Yorhel <git@yorhel.nl> | 2009-10-24 15:19:10 +0200 |
commit | 5251f791de0a0e1684107b373a08cfe3a17fc447 (patch) | |
tree | 53d39d0456b464bf4525020b8503ae2d0c98b1bc /lib/VNDB/DB/Discussions.pm | |
parent | 8243d0b30d015c2464c34b02dd4e3ecf1c599762 (diff) | |
parent | a8921887bddb7242a95e99b5177aff6ff6cd11be (diff) |
Merge branch 'beta'2.8
+ ChangeLog update
Diffstat (limited to 'lib/VNDB/DB/Discussions.pm')
-rw-r--r-- | lib/VNDB/DB/Discussions.pm | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/lib/VNDB/DB/Discussions.pm b/lib/VNDB/DB/Discussions.pm index 26beaaee..60487098 100644 --- a/lib/VNDB/DB/Discussions.pm +++ b/lib/VNDB/DB/Discussions.pm @@ -5,7 +5,7 @@ use strict; use warnings; use Exporter 'import'; -our @EXPORT = qw|dbThreadGet dbThreadEdit dbThreadAdd dbPostGet dbPostEdit dbPostAdd dbThreadCount|; +our @EXPORT = qw|dbThreadGet dbThreadEdit dbThreadAdd dbPostGet dbPostEdit dbPostAdd dbThreadCount dbPostRead|; # Options: id, type, iid, results, page, what, notusers @@ -243,5 +243,15 @@ sub dbPostAdd { } +sub dbPostRead { # thread id, user id, last post number + my($s, $tid, $uid, $num) = @_; + $s->dbExec(q| + UPDATE threads_boards + SET lastread = ? + WHERE tid = ? AND type = 'u' AND iid = ?|, + $num, $tid, $uid); +} + + 1; |