diff options
author | nicodebo <nico.debo@openmailbox.org> | 2017-07-21 00:40:30 +0200 |
---|---|---|
committer | nicodebo <nico.debo@openmailbox.org> | 2017-07-22 12:50:15 +0200 |
commit | 04bb38ff174cb98bf49474bfb5a41d27050a5510 (patch) | |
tree | 1ef2f3f1ab41eb9f970adcc700ab93a00f287819 /README.md | |
parent | 436489984829371f13765d2ac08863bd4f1589d4 (diff) | |
download | perl-app-clerk-04bb38ff174cb98bf49474bfb5a41d27050a5510.tar.gz perl-app-clerk-04bb38ff174cb98bf49474bfb5a41d27050a5510.tar.xz |
Fix albumratings does not exist
The first time rating an album, a FileNotFoundError is raised
because ~/.config/clerk/albumratings.json does not exists:
- Moved the file opening (i.e. load_fastlist) inside the 'try'
block and added an except clause, to catch the FileNotFoundError
exception and process it accordingly.
- Moved the action of saving the json track database and setting the
sticker into a 'finally' block in order not to duplicate lines of code
in the different blocks of the try/except.
- Replaced the 'artist' tag with the 'albumartist' one.
Diffstat (limited to 'README.md')
0 files changed, 0 insertions, 0 deletions