Skip to content

Commit d2040c3

Browse files
committed
Migliorata la stampa dell'errore in caso di validazione errata con tutti gli attributi del model usando ->toJson(JSON_PRETTY_PRINT) del model.
1 parent b37fe54 commit d2040c3

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Validable.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ public function validate()
7070
if (config('laravel-validable.debug')) {
7171
Log::debug('Errore durante la validazione del model \'' . $this->getTable() . '\' in \'' . ($this->id > 0 ? 'update' : 'create') . '\' lanciato su evento saving del model.');
7272
Log::debug('Attributi del model:');
73-
Log::debug(implode(PHP_EOL, $this->attributesToArray()));
73+
Log::debug($this->toJson(JSON_PRETTY_PRINT));
7474
Log::debug('Errori di validazione:');
7575
Log::debug($this->getErrors());
7676
Log::debug('StackTrace:'.PHP_EOL);

0 commit comments

Comments
 (0)