fix picture count bug