fix(database): conditionally set started_at only if the database is running
This commit is contained in:
@@ -33,7 +33,10 @@ class Heading extends Component
|
|||||||
public function activityFinished()
|
public function activityFinished()
|
||||||
{
|
{
|
||||||
try {
|
try {
|
||||||
$this->database->started_at ??= now();
|
// Only set started_at if database is actually running
|
||||||
|
if ($this->database->isRunning()) {
|
||||||
|
$this->database->started_at ??= now();
|
||||||
|
}
|
||||||
$this->database->save();
|
$this->database->save();
|
||||||
|
|
||||||
if (is_null($this->database->config_hash) || $this->database->isConfigurationChanged()) {
|
if (is_null($this->database->config_hash) || $this->database->isConfigurationChanged()) {
|
||||||
|
Reference in New Issue
Block a user