fix dict duplication issue