]> git.sesse.net Git - skvidarsync/blobdiff - www/event.pl
Remove the legacy (non-logged) reactions table.
[skvidarsync] / www / event.pl
index cf7a21283949c74872d0341ef8f6514f6a950221..974352034bca4bf5abc78b0df5ebd75d6bed6dd3 100755 (executable)
@@ -52,14 +52,10 @@ if (exists($json->{'event'}) && exists($json->{'event'}{'type'})) {
        }
 
        if ($type eq 'reaction_added') {
-               $dbh->do('INSERT INTO reactions (userid, channel, ts, reaction) VALUES (?,?,?,?)', undef,
-                       $user, $channel, $ts, $reaction);
                $dbh->do('INSERT INTO reaction_log (userid, channel, ts, reaction, event_type, event_ts) VALUES (?,?,?,?,?,?)', undef,
                        $user, $channel, $ts, $reaction, $type, $event_ts);
                mark();
        } elsif ($type eq 'reaction_removed') {
-               $dbh->do('DELETE FROM reactions WHERE userid=? AND channel=? AND ts=? AND reaction=?', undef,
-                       $user, $channel, $ts, $reaction);
                $dbh->do('INSERT INTO reaction_log (userid, channel, ts, reaction, event_type, event_ts) VALUES (?,?,?,?,?,?)', undef,
                        $user, $channel, $ts, $reaction, $type, $event_ts);
                mark();