aboutsummaryrefslogtreecommitdiffstats
path: root/klippy/extras/save_variables.py
diff options
context:
space:
mode:
Diffstat (limited to 'klippy/extras/save_variables.py')
-rw-r--r--klippy/extras/save_variables.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/klippy/extras/save_variables.py b/klippy/extras/save_variables.py
index 6cedcf46..2e405657 100644
--- a/klippy/extras/save_variables.py
+++ b/klippy/extras/save_variables.py
@@ -36,6 +36,8 @@ class SaveVariables:
cmd_SAVE_VARIABLE_help = "Save arbitrary variables to disk"
def cmd_SAVE_VARIABLE(self, gcmd):
varname = gcmd.get('VARIABLE')
+ if (varname.lower() != varname):
+ raise gcmd.error("VARIABLE must not contain upper case")
value = gcmd.get('VALUE')
try:
value = ast.literal_eval(value)