Fixed: Customer do not call update if there are no updated fields
This commit is contained in:
parent
7e6efc7d4e
commit
01be799d20
2 changed files with 9 additions and 4 deletions
|
|
@ -2,6 +2,7 @@
|
|||
|
||||
### All notable changes to `CRM CLient V2` will be documented in this file.
|
||||
# version 3.0.1
|
||||
- Fixed : Customer do not call update if there are no updated fields
|
||||
- Fixed : WPCrm bootSessionIfNeeded trying to access $_SESSION['wpcrm'] before session was started
|
||||
- Fixed : WPCrm now only returns a boolean
|
||||
- Fixed : get crm info when client used in laravel
|
||||
|
|
|
|||
|
|
@ -445,10 +445,14 @@ class Customer extends CrmClientModel
|
|||
Utils::setRawProperty($this, 'password', null);
|
||||
}
|
||||
return $saved;
|
||||
}
|
||||
if ($saved = $this->update()) {
|
||||
$this->updatedValues = [];
|
||||
Utils::setRawProperty($this, 'password', null);
|
||||
} else {
|
||||
if (empty($this->updatedValues)) {
|
||||
return true;
|
||||
}
|
||||
if ($saved = $this->update()) {
|
||||
$this->updatedValues = [];
|
||||
Utils::setRawProperty($this, 'password', null);
|
||||
}
|
||||
}
|
||||
return $saved;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue