Hi,
Still trying to migrate my Moralis server to our self hosted one (Iām currently using the parse server migration repo to do it) and while trying to convert in TS / integrate my cloud functions and run some tests, Iām running into an issue with the bulkWrite function for some reason, never had this issue before ( I couldnāt test all of my functions yet, hopefully thatās the only one acting funny).
Here is the error I have
Parse.bulkWrite is not a function {ācodeā:141,āstackā:"TypeError: Parse.bulkWrite is not a function
For lisibility/maintainability purposes Iāve split my code into differents files, here is the breadown of it
main.ts
declare const Parse: any;
import { myFunction } from './components/prizes';
[...]
myFunction();
prizes.ts
import { [...], helperFunc } from '../utils/helpers';
declare const Parse: any;
export function myFunction() {
Parse.Cloud.define('myFunction', async (request: any) => {
[...]
helperFunc (p1,p2,p2);
})
}
helpers.ts
declare const Parse: any;
export function helperFunc (p1: any[], p2: string, p3: string) {
[...]
return Parse.bulkWrite('Items', bulkedItems);
}