# HG changeset patch # User neko259 # Date 2017-09-01 12:45:10 # Node ID df3ebb11857c20ca551698d15195a4a4a81c83b6 # Parent 45d3efab8acc81e204ccdf5ba34b1828ff140ce7 Fixed the fix for image download diff --git a/boards/forms/__init__.py b/boards/forms/__init__.py --- a/boards/forms/__init__.py +++ b/boards/forms/__init__.py @@ -360,11 +360,10 @@ class PostForm(NeboardForm): try: image = get_image_by_alias(url, self.session) - if 'stickers' not in self.cleaned_data: - self.cleaned_data['stickers'] = [] - self.cleaned_data['stickers'].append(image) - if image is not None: + if 'stickers' not in self.cleaned_data: + self.cleaned_data['stickers'] = [] + self.cleaned_data['stickers'].append(image) return if file is None: diff --git a/boards/views/thread/thread.py b/boards/views/thread/thread.py --- a/boards/views/thread/thread.py +++ b/boards/views/thread/thread.py @@ -123,7 +123,7 @@ class ThreadView(BaseBoardView, PostMixi post = Post.objects.create_post(title=title, text=text, files=files, thread=post_thread, ip=ip, tripcode=form.get_tripcode(), - file_urls=file_urls) + images=images, file_urls=file_urls) if form.is_subscribe(): settings_manager = get_settings_manager(request)