Commit a0f69168 authored by Guilhem Saurel's avatar Guilhem Saurel
Browse files

populate might be launched several times

parent 3ccd2e5d
......@@ -12,7 +12,8 @@ class Command(BaseCommand):
github = Forge.objects.get(name='Github')
for data in requests.get(f'{github.api_url()}/licenses', headers=github.headers()).json():
License.objects.create(github_key=data['key'], **{key: data[key] for key in ['name', 'spdx_id', 'url']})
**{key: data[key] for key in ['name', 'spdx_id', 'url']})
for forge in Forge.objects.all():
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment