Skip to content

Commit

Permalink
Refactored SearchAsyncTask
Browse files Browse the repository at this point in the history
  • Loading branch information
programarivm committed Oct 8, 2024
1 parent 094fc61 commit b7913ea
Showing 1 changed file with 1 addition and 20 deletions.
21 changes: 1 addition & 20 deletions src/Command/Data/SearchAsyncTask.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,8 @@

use Chess\Movetext\SanMovetext;
use Chess\Variant\Classical\PGN\Move;
use ChessServer\Db;
use Spatie\Async\Task;

class SearchAsyncTask extends Task
class SearchAsyncTask extends AbstractDataAsyncTask
{
const SQL_LIKE = [
'Date',
Expand All @@ -22,23 +20,6 @@ class SearchAsyncTask extends Task
'Result',
];

private array $params;

private array $env;

private Db $db;

public function __construct(array $params, array $env)
{
$this->params = $params;
$this->env = $env;
}

public function configure()
{
$this->db = new Db($this->env['db']);
}

public function run()
{
$sql = 'SELECT * FROM games WHERE ';
Expand Down

0 comments on commit b7913ea

Please sign in to comment.