fix db locked