1
0
Fork 0
mirror of synced 2024-10-02 10:16:27 +13:00

trigger migration

This commit is contained in:
fogelito 2024-05-23 18:14:00 +03:00
parent ecfc5d68c2
commit 0994b0f2de

View file

@ -10,6 +10,7 @@ class Migration extends Event
{
protected string $type = '';
protected ?Document $migration = null;
protected ?Document $backup;
public function __construct(protected Connection $connection)
{
@ -33,6 +34,19 @@ class Migration extends Event
return $this;
}
/**
* Sets backup.
*
* @param Document $backup
* @return self
*/
public function setBackup(Document $backup): self
{
$this->backup = $backup;
return $this;
}
/**
* Returns set migration document for the function event.
*
@ -81,7 +95,8 @@ class Migration extends Event
return $client->enqueue([
'project' => $this->project,
'user' => $this->user,
'migration' => $this->migration
'migration' => $this->migration,
'backup' => $this->backup
]);
}
}