diff --git a/lib/GTSRSSApi.pm b/lib/GTSRSSApi.pm index eb65445..b9ba7f8 100644 --- a/lib/GTSRSSApi.pm +++ b/lib/GTSRSSApi.pm @@ -61,7 +61,7 @@ sub startup ($self) { my $gts_bot_pid = path('last_pid_started_gts_bot'); if (-f $pidfile) { my $pidfile_content = $pidfile->slurp; - if ($pidfile_content eq $gts_bot_pid->slurp) { + if (-f $gts_bot_pid && $pidfile_content eq $gts_bot_pid->slurp) { return; } $gts_bot_pid->spew($pidfile_content);