fix: should be able to reset labels in read-only mode with manual click

This commit is contained in:
Andras Bacsai
2024-10-22 11:25:03 +02:00
parent bfd6923ba6
commit c338eef57b
2 changed files with 3 additions and 3 deletions

View File

@@ -274,10 +274,10 @@ class General extends Component
}
}
public function resetDefaultLabels()
public function resetDefaultLabels($manualReset = false)
{
try {
if ($this->application->settings->is_container_label_readonly_enabled) {
if ($this->application->settings->is_container_label_readonly_enabled && ! $manualReset) {
return;
}
$this->customLabels = str(implode('|coolify|', generateLabelsApplication($this->application)))->replace('|coolify|', "\n");