// this properly updates my object
req.user.scienceViewsData = {
'asdf' : {
one: 'asdf',
two: 'asdf'
}
}
// why doesn't this work?
req.user.scienceViewsData['asdf'] = {
one: '1234',
two: '1234'
};
await req.user.save();
使用架构类型混合。为什么这行不通?