mirror of
https://github.com/strapi/strapi.git
synced 2025-09-01 12:53:03 +00:00
fix bug
(const variable is assigned it cannot be assigned again and an attempt to do so will throw an error)
This commit is contained in:
parent
267c4e1675
commit
c5bb2da0a4
@ -457,7 +457,7 @@ module.exports = function(strapi) {
|
||||
result.value = parseFloat(value);
|
||||
break;
|
||||
default:
|
||||
result = undefined;
|
||||
return undefined;
|
||||
}
|
||||
|
||||
return result;
|
||||
@ -622,7 +622,7 @@ module.exports = function(strapi) {
|
||||
switch (association.nature) {
|
||||
case 'oneToOne':
|
||||
case 'oneToMany':
|
||||
return this.manageRelations(model, params)
|
||||
return this.manageRelations(model, params);
|
||||
case 'manyToMany':
|
||||
return Model.forge({
|
||||
[Model.primaryKey]: parseFloat(params[Model.primaryKey])
|
||||
@ -645,7 +645,7 @@ module.exports = function(strapi) {
|
||||
switch (association.nature) {
|
||||
case 'oneToOne':
|
||||
case 'oneToMany':
|
||||
return this.manageRelations(model, params)
|
||||
return this.manageRelations(model, params);
|
||||
case 'manyToMany':
|
||||
return Model.forge({
|
||||
[Model.primaryKey]: parseFloat(params[Model.primaryKey])
|
||||
|
Loading…
x
Reference in New Issue
Block a user