Skip to content
Browse files

Reversed the create options.

  • Loading branch information...
1 parent 42db96d commit 1de9f1c23d8d10d5f53043fcf6b6a69016f9e84a @BrianAker BrianAker committed
Showing with 3 additions and 3 deletions.
  1. +1 −1 plugins/Stats/Stats.pm
  2. +2 −2 plugins/Stats/adminmail.pl
View
2 plugins/Stats/Stats.pm
@@ -37,7 +37,7 @@ sub new {
? $options->{day}
: sprintf("%4d-%02d-%02d", $yest_lt[5] + 1900, $yest_lt[4] + 1, $yest_lt[3]);
- unless ($options->{use_current}) {
+ if ($options->{create}) {
$self->sqlDo("DROP TABLE IF EXISTS accesslog_temp");
my $sth = $self->{_dbh}->prepare("SHOW CREATE TABLE accesslog");
$sth->execute();
View
4 plugins/Stats/adminmail.pl
@@ -24,10 +24,10 @@
my $statsSave = getObject('Slash::Stats::Writer', '', { day => $yesterday });
# This will need to be changed to "log_db_user"
if ($constants->{backup_db_user}) {
- $stats = getObject('Slash::Stats', $constants->{backup_db_user}, { day => $yesterday });
+ $stats = getObject('Slash::Stats', $constants->{backup_db_user}, { day => $yesterday, create => 1 });
$backupdb = getObject('Slash::DB', $constants->{backup_db_user});
} else {
- $stats = getObject('Slash::Stats');
+ $stats = getObject('Slash::Stats', "", { day => $yesterday, create => 1 });
$backupdb = $slashdb;
}

0 comments on commit 1de9f1c

Please sign in to comment.
Something went wrong with that request. Please try again.