mirror of
https://github.com/viq/NewsBlur.git
synced 2025-09-18 21:43:31 +00:00
Fixing issue with PuSH hub topic's being too long for the db.
This commit is contained in:
parent
57ebbb0790
commit
6b202ebba5
1 changed files with 4 additions and 1 deletions
|
@ -34,7 +34,10 @@ class PushSubscriptionManager(models.Manager):
|
|||
subscription, created = self.get_or_create(feed=feed)
|
||||
signals.pre_subscribe.send(sender=subscription, created=created)
|
||||
subscription.set_expiration(lease_seconds)
|
||||
subscription.topic = topic
|
||||
if len(topic) < 200:
|
||||
subscription.topic = topic
|
||||
else:
|
||||
subscription.topic = feed.feed_link[:200]
|
||||
subscription.hub = hub
|
||||
subscription.save()
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue