Skip to content

Commit 420cac3

Browse files
committed
fix(dashboard); clone template in updating bin init
1 parent c060e47 commit 420cac3

1 file changed

Lines changed: 1 addition & 5 deletions

File tree

assets/dashboard.html

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -944,11 +944,7 @@ <h5 class="mb-3">Body</h5>
944944
newIP: "",
945945
responseType: /** @type {"capture" | "template"} */ (Object.entries(bin.responding)[0][0]),
946946
newResponseHeader: "",
947-
template: template !== undefined ? {
948-
status: template.status,
949-
headers: template.headers,
950-
body: template.body,
951-
} : defaultTemplate,
947+
template: template !== undefined ? JSON.parse(JSON.stringify(template)) : defaultTemplate,
952948
}
953949
} else {
954950
this.updatingBin = {

0 commit comments

Comments
 (0)