2
0
mirror of https://github.com/codl/forget synced 2024-12-25 14:42:41 +01:00

removing counters: take two

This commit is contained in:
codl 2021-05-14 20:32:09 +02:00
parent f3e68e7fb4
commit 159c1826d3
2 changed files with 0 additions and 7 deletions

View File

@ -115,10 +115,6 @@ def post_from_api_tweet_object(tweet, post=None):
if 'entities' in tweet:
post.has_media = bool(
'media' in tweet['entities'] and tweet['entities']['media'])
if 'favorite_count' in tweet:
post.favourites = tweet['favorite_count']
if 'retweet_count' in tweet:
post.reblogs = tweet['retweet_count']
post.is_reblog = 'retweeted_status' in tweet
return post

View File

@ -302,9 +302,6 @@ class Post(db.Model, TimestampMixin, RemoteIDMixin):
has_media = db.Column(db.Boolean, server_default='FALSE', nullable=False)
direct = db.Column(db.Boolean, server_default='FALSE', nullable=False)
favourites = db.Column(db.Integer)
reblogs = db.Column(db.Integer)
is_reblog = db.Column(db.Boolean, server_default='FALSE', nullable=False)
def __str__(self):