fix object creating bug.