Skip to content
This repository has been archived by the owner on Jul 18, 2022. It is now read-only.

Commit

Permalink
Minor code cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
ardevd committed May 14, 2017
1 parent 6aeca38 commit 05db019
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions pyand/Fastboot.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
#!/usr/bin/env python2

try:
import sys
import subprocess
Expand Down Expand Up @@ -77,7 +78,6 @@ def run_cmd(self, cmd):
args = self.__build_command__(cmd)
if args is None:
return
#print 'args>', args
cmdp = subprocess.Popen(args, shell=False, stdout=subprocess.PIPE, stderr=subprocess.STDOUT)
self.__output, self.__error = cmdp.communicate()
retcode = cmdp.wait()
Expand Down Expand Up @@ -115,7 +115,7 @@ def get_devices(self):
fastboot devices
"""
error = 0
#Clear existing list of devices
# Clear existing list of devices
self.__devices = None
self.run_cmd("devices")
if self.__error is not None:
Expand All @@ -129,11 +129,10 @@ def get_devices(self):
except:
self.__devices = None
error = 1
#return (error,self.__devices)
i = 0
device_dict = {}
for device in device_list:
#Add list to dictionary with incrementing ID
# Add list to dictionary with incrementing ID
device_dict[i] = device
i += 1
self.__devices = device_dict
Expand Down

0 comments on commit 05db019

Please sign in to comment.