Fix some bugs on main, policy