mirror of
https://github.com/snipe/snipe-it.git
synced 2025-02-21 03:15:45 -08:00
Removed debugging
Signed-off-by: snipe <snipe@snipe.net>
This commit is contained in:
parent
2b9e4110bc
commit
766eee78b2
|
@ -63,12 +63,11 @@ class ValidationServiceProvider extends ServiceProvider
|
|||
* `unique_undeleted:table,fieldname` in your rules out of the box
|
||||
*/
|
||||
Validator::extend('unique_undeleted', function ($attribute, $value, $parameters, $validator) {
|
||||
|
||||
|
||||
if (count($parameters)) {
|
||||
|
||||
// This is a bit of a shim, but serial doesn't have any other rules around it other than that it's nullable
|
||||
if (($parameters[0]=='assets') && ($attribute == 'serial') && (Setting::getSettings()->unique_serial != '1')) {
|
||||
\Log::debug('Checking for serial and it is not unique');
|
||||
return true;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue