fixed a register issue in model