Forgot to urlencode the list of URLs posted up to Superfeedr

This commit is contained in:
Danielle McLean 2017-11-06 11:49:43 +11:00
parent 45298abb98
commit 475302eb07
Signed by: 00dani
GPG key ID: 5A5D2D1AFF12EEC5

View file

@ -1,11 +1,12 @@
import requests import requests
from django.conf import settings from django.conf import settings
from django_rq import job from django_rq import job
from urllib.parse import urlencode
@job @job
def ping_hub(*urls): def ping_hub(*urls):
requests.post(settings.PUSH_HUB, data={ requests.post(settings.PUSH_HUB, data={
'hub.mode': 'publish', 'hub.mode': 'publish',
'hub.url': ','.join(urls), 'hub.url': ','.join(map(urlencode, urls)),
}) })