fix matrix ID Bug