Comments (3)
Did a little more digging.
It looks like a variable scoping issue. When the object key matches the metadata constant (@metadata
), skipTypes
is clobbered, forever set to true
until the recursive function finishes.
ravendb-nodejs-client/src/Mapping/ObjectMapper.ts
Lines 449 to 454 in 70834f6
We were able to work around the issue by making this change:
let innerSkipTypes = skipTypes
if (!skipTypes) {
innerSkipTypes = key === CONSTANTS.Documents.Metadata.KEY;
}
const fullPath = objPathPrefix ? `${objPathPrefix}.${nestedTypeInfoKey}` : nestedTypeInfoKey;
result[key] = this._makeObjectLiteral(obj[key], fullPath, typeInfoCallback, knownTypes, innerSkipTypes);
from ravendb-nodejs-client.
from ravendb-nodejs-client.
@jhahn Fixed. This for reporting this issue and very clear explanation and solution suggestion.
from ravendb-nodejs-client.
Related Issues (20)
- Feature description update HOT 1
- Using load with includes returns null for documents that were previously stored HOT 2
- Cannot find type definition file for 'stream-json' HOT 2
- Issue with 5.0.1 HOT 3
- Map/Reduce in NodeJs HOT 2
- Can I use the as clause? HOT 2
- TimeSeriesRangeAggregation.asTypedEntry not producing expected results HOT 3
- Getting started error HOT 4
- Serialisation issue HOT 2
- load methods could reasonably return null and interface should reflect that HOT 7
- Activating `queryCustomization.randomOrdering` ignores Collection parameter and returns from all Collections HOT 2
- error TS2507: Type 'typeof FilterBase' is not a constructor function type. HOT 8
- Properly handle large requests using multi byte chars
- Provide a way for closing sessions manually HOT 7
- Question: check for unsaved changes in session HOT 1
- Map/Reduce TypeError: Object has no method 'flat' HOT 3
- Incorrect ModifiedDocument returned in afterSaveChanges session event HOT 6
- GetDatabaseOperation throws when response is "successfully" a 404 HOT 9
- Type clash with @types/node HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from ravendb-nodejs-client.