adding .jpg to filename if it don't finish with .jpg