fixes #4881 Repeats and Category values can not loaded

Fixed the issue and committed code for review, please check it.