Fixed crash on operator select cancel

andrejusk/bday
Alistair MacDonald 2018-09-01 11:17:01 +01:00 committed by GitHub
parent 3c0b33282a
commit f8102d5652
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 7 additions and 6 deletions

View File

@ -139,6 +139,7 @@ def selectoperator():
for op in sim800.listoperators():
opset.append({ "title" : op[1], "index" : op[3] })
selectedop = prompt_option(opset, text="Operator", select_text="Select", none_text="Cancel")
if selectedop:
if selectedop["index"]==-1:
sim800.setoperator(0)
notice("perator selection set to automatic.", title="TiLDA Phone")