fix  it is crash when you scan the  photo faster.