Fix sync issue 

There was a problem with sync albums and images there was a small bug in the code that I corrected.