Skip to content

Commit

Permalink
update repositories with new data
Browse files Browse the repository at this point in the history
  • Loading branch information
Gummibeer committed Aug 26, 2024
1 parent caa18d9 commit d6fc9de
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion app/Models/Repository.php
Original file line number Diff line number Diff line change
Expand Up @@ -115,11 +115,13 @@ public static function fromGithub(array $data): ?self
$repository = self::query()->withBlocked()->firstOrNew([
'id' => $data['id'],
], [
'block_reason' => $blockReason ?? null,
]);
$repository->fill([
'name' => $data['full_name'],
'description' => $data['description'],
'language' => $data['language'] ?? Language::NOASSERTION(),
'license' => $data['license']['spdx_id'],
'block_reason' => $blockReason ?? null,
'stargazers_count' => $data['stargazers_count'],
'website' => $data['homepage'],
]);
Expand Down

0 comments on commit d6fc9de

Please sign in to comment.