Skip to content
Snippets Groups Projects
Commit ad540448 authored by Moul's avatar Moul
Browse files

[fix] #692: check certification file value is not empty.

parent 75a7e9e3
No related branches found
No related tags found
1 merge request!693Check certification file value is not empty
......@@ -89,7 +89,7 @@ class CertificationView(QWidget, Ui_CertificationWidget):
file_name = QFileDialog.getOpenFileName(self,
self.tr("Open identity document"), "",
self.tr("Duniter documents (*.txt)"))
if file_name:
if file_name and file_name[0]:
with open(file_name[0], 'r') as open_file:
raw_text = open_file.read()
try:
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment