From 564e1cc3e4b3994d7d1c52c9fe596124a3ee5ff6 Mon Sep 17 00:00:00 2001 From: jwanek Date: Tue, 26 May 2020 20:00:40 +0100 Subject: added adding timestamp --- subreddit.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'subreddit.py') diff --git a/subreddit.py b/subreddit.py index dbb2e1e..8a1755d 100755 --- a/subreddit.py +++ b/subreddit.py @@ -170,7 +170,7 @@ def handle_givelambda(comment): text = "Please only give lambda to humans." elif str(comment.author) in get_mods(): text = "The moderator /u/%s has given /u/%s 1λ. /u/%s now has %iλ." % (str(comment.author), parentauthour, parentauthour, db.get_lambda(parentauthour)[0] + 1) - db.give_lambda(parentauthour, submission.permalink) + db.give_lambda(parentauthour, submission.permalink, timestamp = int(submission.created_utc)) display(text) elif submission.link_flair_text in FREE_FLAIRS: text = "You cannot give lambda in free posts anymore." @@ -187,7 +187,7 @@ def handle_givelambda(comment): # db.give_lambda(parentauthour, submission.permalink, op) # display("The OP received lambda too!") # else: - db.give_lambda(parentauthour, submission.permalink) + db.give_lambda(parentauthour, submission.permalink, timestamp = int(submission.created_utc)) # update_users_flair_from_comment(comment) update_users_flair_from_comment(comment.parent()) -- cgit v1.2.3