Fix model queries values not matching placeholder count

This commit is contained in:
Alice Gaudon 2020-07-28 15:01:59 +02:00
parent 31f974c0a6
commit 37ed42b37d

View File

@ -272,7 +272,9 @@ class FieldValue {
} }
public get variables(): any[] { public get variables(): any[] {
return this.value instanceof ModelQuery ? this.value.variables : [this.value]; if (this.value instanceof ModelQuery) return this.value.variables;
if (this.raw || this.value === null) return [];
return [this.value];
} }
} }