fix db lock when get date from db