fix bug: should not save localizer data to database while the main model is not been saved!