Skip to content

Commit

Permalink
Fix #175: Nw versions not updating if version file is empty
Browse files Browse the repository at this point in the history
  • Loading branch information
jyapayne committed Dec 14, 2016
1 parent 3452995 commit 4aa74f5
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 13 deletions.
2 changes: 1 addition & 1 deletion command_line.py
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ def setup_nw_versions(self):
for line in f:
nw_version.values.append(line.strip())
except IOError:
nw_version.values.append(nw_version.default_value)
pass

def get_nw_versions(self):
"""Get the already downloaded nw versions from the settings"""
Expand Down
12 changes: 0 additions & 12 deletions main.py
Original file line number Diff line number Diff line change
Expand Up @@ -210,18 +210,6 @@ def open_recent_file(self):
if action:
self.load_project(action.data())

def setup_nw_versions(self):
"""Loads stored versions that were previously retrieved."""
nw_version = self.get_setting('nw_version')
try:
f = codecs.open(utils.get_data_file_path(config.VER_FILE),
encoding='utf-8')
for line in f:
nw_version.values.append(line.strip())
f.close()
except IOError:
nw_version.values.append(nw_version.default_value)

def create_application_layout(self):
"""Create all widgets and set the central widget."""
self.main_layout = QtGui.QVBoxLayout()
Expand Down

0 comments on commit 4aa74f5

Please sign in to comment.