Refined some logics.