Skip to content

Commit 249f8b3

Browse files
committed
Fixed an issue with removing quotes in DNS records
1 parent 4e0e804 commit 249f8b3

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

interface/web/dns/dns_edit_base.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -129,9 +129,9 @@ function onSubmit() {
129129

130130
if($this->checkDuplicate()) $app->tform->errorMessage .= $app->tform->lng("data_error_duplicate")."<br>";
131131

132-
// Remove accidental quotes around a record.
132+
// Remove accidental quotes around a record
133133
$matches = array();
134-
if(preg_match('/^"(.*)"$/', $this->dataRecord["data"], $matches)) {
134+
if(substr_count($this->dataRecord["data"], '"') == 2 && preg_match('/^"(.*)"$/', $this->dataRecord["data"], $matches)) {
135135
$this->dataRecord["data"] = $matches[1];
136136
}
137137

0 commit comments

Comments
 (0)