Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
themsaid committed Oct 23, 2018
1 parent 77deb04 commit 8203efb
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions src/Console/PruneCommand.php
Expand Up @@ -3,7 +3,7 @@
namespace Laravel\Telescope\Console;

use Illuminate\Console\Command;
use Laravel\Telescope\Contracts\PrunableRepository;
use Laravel\Telescope\Contracts\EntriesRepository;

class PruneCommand extends Command
{
Expand All @@ -24,11 +24,13 @@ class PruneCommand extends Command
/**
* Execute the console command.
*
* @param \Laravel\Telescope\Contracts\PrunableRepository $storage
* @param \Laravel\Telescope\Contracts\EntriesRepository $storage
* @return void
*/
public function handle(PrunableRepository $storage)
public function handle(EntriesRepository $storage)
{
$this->info($storage->prune(now()->subHours(24)).' entries pruned.');
if (method_exists($storage, 'prune')) {
$this->info($storage->prune(now()->subHours(24)).' entries pruned.');
}
}
}

0 comments on commit 8203efb

Please sign in to comment.