Spaces:
Runtime error
Runtime error
Download static/node_modules/mongoose/lib/schema/operators/helpers.js from kaab4321/NarrativeFlow: direct link, hf CLI and curl.
- Browser
- Download file 493 Bytes
-
https://huggingface.co/spaces/kaab4321/NarrativeFlow/resolve/main/static/node_modules/mongoose/lib/schema/operators/helpers.js
- Command line
-
hf download hf://spaces/kaab4321/NarrativeFlow/static/node_modules/mongoose/lib/schema/operators/helpers.js
-
curl -L -o helpers.js https://huggingface.co/spaces/kaab4321/NarrativeFlow/resolve/main/static/node_modules/mongoose/lib/schema/operators/helpers.js
493 Bytes
| ; | |
| /*! | |
| * Module requirements. | |
| */ | |
| const SchemaNumber = require('../number'); | |
| /*! | |
| * ignore | |
| */ | |
| exports.castToNumber = castToNumber; | |
| exports.castArraysOfNumbers = castArraysOfNumbers; | |
| /*! | |
| * ignore | |
| */ | |
| function castToNumber(val) { | |
| return SchemaNumber.cast()(val); | |
| } | |
| function castArraysOfNumbers(arr, self) { | |
| arr.forEach(function(v, i) { | |
| if (Array.isArray(v)) { | |
| castArraysOfNumbers(v, self); | |
| } else { | |
| arr[i] = castToNumber.call(self, v); | |
| } | |
| }); | |
| } | |