summaryrefslogtreecommitdiff
path: root/cat.py
diff options
context:
space:
mode:
Diffstat (limited to 'cat.py')
-rw-r--r--cat.py7
1 files changed, 3 insertions, 4 deletions
diff --git a/cat.py b/cat.py
index 36659ed..86e9af4 100644
--- a/cat.py
+++ b/cat.py
@@ -52,7 +52,7 @@ class VnilCat:
exit()
self.intimacy = {}
print("[booting] init intimacy")
- self.update_intimacy(self)
+ self.update_intimacy()
# try to fetch the lastest status from the timeline
# so that we can skip the ones before we start.
@@ -69,7 +69,7 @@ class VnilCat:
print(f"[booting] Cat booted, all systems green, my name is {self.config.UNAME}, prepare to die, human")
print("-------------")
- def update_intimacy():
+ def update_intimacy(self):
res = self.db.count_interaction()
if res != None:
self.intimacy = res
@@ -105,7 +105,7 @@ class VnilCat:
def catch_birds(self, status, content):
- if re_contains_bird.search(content) is not None and len(content) < 10:
+ if re_contains_bird.search(content) is not None and len(content) < self.config.CATCH_BIRD_MAX_LENGTH:
print("i see a bird", status["id"], " from ", status["account"]["acct"])
try:
s = self.session.status_reply(
@@ -149,7 +149,6 @@ class VnilCat:
# important! make sure to iterate from older status to newer
# otherwise the 'last_seen' won't be updated correctly
for status in reversed(tl):
- # skip if it's from myself
self.handle_home_status(status=status)
# For now we don't handle other interaction types