Skip to content

Commit 5a1d24d

Browse files
committed
[processing] fix #10659
1 parent f4cb03a commit 5a1d24d

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

python/plugins/processing/script/AddScriptFromFileAction.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,6 @@ def execute(self):
5151
QtGui.QMessageBox.warning(self.toolbox, "Error reading script", "The selected file does not contain a valid script")
5252
return
5353
destFilename = os.path.join(ScriptUtils.scriptsFolder(), os.path.basename(filename))
54-
with open(destFilename) as f:
54+
with open(destFilename, "w") as f:
5555
f.write(script.script)
5656
self.toolbox.updateProvider('script')

0 commit comments

Comments
 (0)