fix: snaps read index error

This commit is contained in:
Vinicius Moreira
2019-07-26 13:50:20 -03:00
parent fd9bcd43e7
commit 8f9f8d04db
3 changed files with 7 additions and 3 deletions

View File

@@ -4,6 +4,10 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
## [0.4.2]
### Fixes:
- [Snaps read index error](https://github.com/vinifmor/fpakman/issues/30)
## [0.4.1] - 2019-07-25
### Improvements
- retrieving some Snaps data (icon, description and confinement) through Ubuntu API instead of Snap Store

View File

@@ -1,4 +1,4 @@
__version__ = '0.4.1'
__version__ = '0.4.2'
__app_name__ = 'fpakman'
import os

View File

@@ -39,8 +39,8 @@ def app_str_to_json(app: str) -> dict:
'version': app_data[1],
'rev': app_data[2],
'tracking': app_data[3],
'publisher': app_data[4],
'notes': app_data[5]
'publisher': app_data[4] if len(app_data) >= 5 else None,
'notes': app_data[5] if len(app_data) >= 6 else None
}
app_json.update(get_info(app_json['name'], ('summary', 'type', 'description')))