From 78176b1d108006dec356c6507109fd47da27bd93 Mon Sep 17 00:00:00 2001 From: Raphael Forment Date: Thu, 28 Sep 2023 22:20:41 +0200 Subject: [PATCH] fix copy script function --- src/API.ts | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/API.ts b/src/API.ts index d3d3f2a..85bb809 100644 --- a/src/API.ts +++ b/src/API.ts @@ -286,8 +286,9 @@ export class UserAPI { * @param from - The script to copy from * @param to - The script to copy to */ - this.app.universes[this.app.selected_universe].locals[to] = - this.app.universes[this.app.selected_universe].locals[from]; + this.app.universes[this.app.selected_universe].locals[to] = { + ...this.app.universes[this.app.selected_universe].locals[from], + }; }; cps = this.copy_script;