Skip to content

Commit

Permalink
Some minor convenience changes
Browse files Browse the repository at this point in the history
  • Loading branch information
MCMi460 committed Jan 2, 2023
1 parent 6b7af62 commit 5858a54
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
2 changes: 1 addition & 1 deletion client/api/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ def getVersion():
log('Failed to get Apple\'s store page. Retrying...')
searchPattern = re.compile(r'Version\s*(\d\.\d\.\d)+')
version = searchPattern.findall(r.text)
if version == []:
if not version:
return ''
pattern = re.compile(r'(\d.\d.\d)')
if not re.search(pattern, version[0]):
Expand Down
6 changes: 5 additions & 1 deletion client/app.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,11 @@
session_token, user_lang, targetID = getToken(False)
version = getVersion()
while not version:
version, ok = QInputDialog.getText(MainWindow, 'Version Number', 'What is the current version of the Nintendo Switch Online Mobile app?\nThe App Store says it is %s (Please enter like X.X.X)' % version)
version, ok = QInputDialog.getText(MainWindow, 'Version Number', 'What is the current version of the Nintendo Switch Online Mobile app?\nThe App Store says it is %s (Please enter like X.X.X)\nEnter nothing and press Okay to be sent to the app store\'s website.' % version)
if not ok:
quit()
if ok and not version:
webbrowser.open('https://apps.apple.com/us/app/nintendo-switch-online/id1234806557')
try:
client = Discord(session_token, user_lang, False, targetID, version)
except Exception as e:
Expand Down

0 comments on commit 5858a54

Please sign in to comment.