Scrutinizer GitHub App not installed

We could not synchronize checks via GitHub's checks API since Scrutinizer's GitHub App is not installed for this repository.

Install GitHub App

Code Duplication    Length = 12-14 lines in 2 locations

src/CrudTrait.php 2 locations

@@ 143-154 (lines=12) @@
140
        }
141
142
        // if a new file is uploaded, store it on disk and its filename in the database
143
        if ($request->hasFile($attribute_name) && $request->file($attribute_name)->isValid()) {
144
145
            // 1. Generate a new file name
146
            $file = $request->file($attribute_name);
147
            $new_file_name = md5($file->getClientOriginalName().time()).'.'.$file->getClientOriginalExtension();
148
149
            // 2. Move the new file to the correct path
150
            $file_path = $file->storeAs($destination_path, $new_file_name, $disk);
151
152
            // 3. Save the complete path to the database
153
            $this->attributes[$attribute_name] = $file_path;
154
        }
155
    }
156
157
    /**
@@ 191-204 (lines=14) @@
188
        }
189
190
        // if a new file is uploaded, store it on disk and its filename in the database
191
        if ($request->hasFile($attribute_name)) {
192
            foreach ($request->file($attribute_name) as $file) {
193
                if ($file->isValid()) {
194
                    // 1. Generate a new file name
195
                    $new_file_name = md5($file->getClientOriginalName().time()).'.'.$file->getClientOriginalExtension();
196
197
                    // 2. Move the new file to the correct path
198
                    $file_path = $file->storeAs($destination_path, $new_file_name, $disk);
199
200
                    // 3. Add the public path to the database
201
                    $attribute_value[] = $file_path;
202
                }
203
            }
204
        }
205
206
        $this->attributes[$attribute_name] = json_encode($attribute_value);
207
    }