Passed
Branch master (c145be)
by Faidz
04:31
created
src/UuidTrait.php 1 patch
Spacing   +3 added lines, -4 removed lines patch added patch discarded remove patch
@@ -34,18 +34,17 @@
 block discarded – undo
34 34
      */
35 35
     public static function bootUuidTrait()
36 36
     {
37
-        static::creating(function ($model) {
37
+        static::creating(function($model) {
38 38
             // Only generate UUID if it wasn't set by already.
39 39
             $key = $model->getKeyName();
40 40
             if (!isset($model->attributes[$key])) {
41
-                $uuidVersion = (!empty($model->uuidVersion) ? $model->uuidVersion : 4);   // defaults to 4
41
+                $uuidVersion = (!empty($model->uuidVersion) ? $model->uuidVersion : 4); // defaults to 4
42 42
                 $uuid = call_user_func('Ramsey\Uuid\Uuid::uuid' . $uuidVersion);
43 43
 
44 44
                 $model->attributes[$key] = (
45 45
                     property_exists($model, 'uuidOptimization') &&
46 46
                     $model::$uuidOptimization ?
47
-                        $model::toOptimized($uuid->toString()) :
48
-                        $uuid->getBytes()
47
+                        $model::toOptimized($uuid->toString()) : $uuid->getBytes()
49 48
                     )
50 49
                 ;
51 50
             }
Please login to merge, or discard this patch.
src/BaseModel.php 1 patch
Indentation   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -7,7 +7,7 @@
 block discarded – undo
7 7
 
8 8
 abstract class BaseModel extends Model
9 9
 {
10
-	use UuidTrait;
10
+    use UuidTrait;
11 11
 	
12
-	protected $model;
12
+    protected $model;
13 13
 }
14 14
\ No newline at end of file
Please login to merge, or discard this patch.