Skip to content
Permalink
Browse files
Update Setup.py
  • Loading branch information
carreira committed Nov 30, 2018
1 parent 1e7266c commit 956eb0b09383b1f4a43ccdaf49560e8ae933ddf6
Showing 1 changed file with 3 additions and 0 deletions.
@@ -57,6 +57,7 @@ def reset():

'''The "arg" is taken from the main code. It is either 0 or 1, depend on which argument from the file we need, either name or city.'''
def load_setting(arg):
try:
settings_file = open("settings.txt")
if arg == 0:
for setting in settings_file:
@@ -70,3 +71,5 @@ def load_setting(arg):
city = setting.replace('city:','') #Similar to above, but argument city which was defined by the user as an input on beginning can be used in function weather_ask.
settings_file.close()
return city
except:
pass

0 comments on commit 956eb0b

Please sign in to comment.