Check whether getUpdateOnlyProperties is a fn
This commit is contained in:
parent
0f40ca8f8e
commit
131aafcef9
|
@ -761,7 +761,7 @@ module.exports = function(registry) {
|
||||||
// if there is atleast one updateOnly property, then we set
|
// if there is atleast one updateOnly property, then we set
|
||||||
// createOnlyInstance flag in __create__ to indicate loopback-swagger
|
// createOnlyInstance flag in __create__ to indicate loopback-swagger
|
||||||
// code to create a separate model instance for create operation only
|
// code to create a separate model instance for create operation only
|
||||||
const updateOnlyProps = this.getUpdateOnlyProperties();
|
const updateOnlyProps = this.getUpdateOnlyProperties ? this.getUpdateOnlyProperties() : false;
|
||||||
const hasUpdateOnlyProps = updateOnlyProps && updateOnlyProps.length > 0;
|
const hasUpdateOnlyProps = updateOnlyProps && updateOnlyProps.length > 0;
|
||||||
|
|
||||||
var isStatic = scope.isStatic;
|
var isStatic = scope.isStatic;
|
||||||
|
|
Loading…
Reference in New Issue