Commit b6b8b612 authored by Luuk Scholten's avatar Luuk Scholten
Browse files

During member migration, check if basename of images contains query string

parent f0cbd8b2
......@@ -17,8 +17,12 @@ from members.models import Member, Membership
def imagefield_from_url(imagefield, url):
basename = os.path.basename(url)
if '?' in basename:
basename = '?'.join(basename.split('?')[:-1])
file = ContentFile(requests.get(url).content), file), file)
class Command(BaseCommand):
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