fixed bug/crash when no pictures are available.