fix: enforce unique national ID validation and fix sync updated_at corruption
This commit is contained in:
@@ -38,8 +38,10 @@ public function updated(Model $model): void
|
||||
}
|
||||
|
||||
$changedData = [];
|
||||
foreach ($dirty as $field => $newValue) {
|
||||
$changedData[$field] = $model->getAttribute($field);
|
||||
foreach ($dirty as $field => $rawValue) {
|
||||
$changedData[$field] = $rawValue instanceof \BackedEnum
|
||||
? $rawValue->value
|
||||
: (is_object($rawValue) ? (string) $rawValue : $rawValue);
|
||||
}
|
||||
|
||||
SyncLog::create([
|
||||
|
||||
Reference in New Issue
Block a user