Fix the bug that reference field is not working.

I changed to use ScriptableObjectId instead of using ObjectId itself for
reference field. But I missed to fix here.