Fixed Indentation error (#15210)
* Fixed Indentation error * Update xiaomi.py
This commit is contained in:
parent
e3e014bccc
commit
c61a652c90
1 changed files with 4 additions and 2 deletions
|
@ -113,6 +113,7 @@ class XiaomiCamera(Camera):
|
||||||
except error_perm as exc:
|
except error_perm as exc:
|
||||||
_LOGGER.error('Unable to find path: %s - %s', first_dir, exc)
|
_LOGGER.error('Unable to find path: %s - %s', first_dir, exc)
|
||||||
return False
|
return False
|
||||||
|
|
||||||
if self._model == MODEL_XIAOFANG:
|
if self._model == MODEL_XIAOFANG:
|
||||||
dirs = [d for d in ftp.nlst() if '.' not in d]
|
dirs = [d for d in ftp.nlst() if '.' not in d]
|
||||||
if not dirs:
|
if not dirs:
|
||||||
|
@ -121,6 +122,7 @@ class XiaomiCamera(Camera):
|
||||||
|
|
||||||
latest_dir = dirs[-1]
|
latest_dir = dirs[-1]
|
||||||
ftp.cwd(latest_dir)
|
ftp.cwd(latest_dir)
|
||||||
|
|
||||||
videos = [v for v in ftp.nlst() if '.tmp' not in v]
|
videos = [v for v in ftp.nlst() if '.tmp' not in v]
|
||||||
if not videos:
|
if not videos:
|
||||||
_LOGGER.info('Video folder "%s" is empty; delaying', latest_dir)
|
_LOGGER.info('Video folder "%s" is empty; delaying', latest_dir)
|
||||||
|
|
Loading…
Add table
Reference in a new issue