Skip to content

Commit

Permalink
fix: handle missing streamcontrol json
Browse files Browse the repository at this point in the history
  • Loading branch information
NikhilNarayana committed Jan 24, 2022
1 parent 3f25469 commit c65b83b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions meleeuploader/forms.py
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ def __init__(self, mappings={}):
self._button.value = self.__button_action

def __button_action(self, data=None):
if self._file.value:
if self._file.value and os.path.exists(self._file.value):
self._mappings["file"] = self._file.value
self._mappings["p1_name"] = self._p1.value
self._mappings["p2_name"] = self._p2.value
Expand All @@ -140,7 +140,7 @@ def __button_action(self, data=None):
json.dump(self._mappings, f)
self.parent._MeleeUploader__hook_sc(self._mappings)
else:
self.warning("You must select a file")
self.warning("You must select a file", "MeleeUploader")


class SMurlInput(BaseWidget):
Expand Down

0 comments on commit c65b83b

Please sign in to comment.