Update syntax for styleci (#1700)

This commit is contained in:
Lance Pioch 2019-09-23 15:30:51 -04:00 committed by Dane Everitt
parent 67ff67a1bd
commit 513965dac7
1 changed files with 2 additions and 2 deletions

View File

@ -104,7 +104,7 @@ abstract class Validable extends Model
public static function getRulesForUpdate($id, string $primaryKey = 'id')
{
if ($id instanceof Model) {
list($primaryKey, $id) = [$id->getKeyName(), $id->getKey()];
[$primaryKey, $id] = [$id->getKeyName(), $id->getKey()];
}
$rules = static::getRules();
@ -118,7 +118,7 @@ abstract class Validable extends Model
continue;
}
list(, $args) = explode(':', $datum);
[, $args] = explode(':', $datum);
$args = explode(',', $args);
$datum = Rule::unique($args[0], $args[1] ?? $key)->ignore($id, $primaryKey)->__toString();