Use post id to generate summary class (#583)

Removes the "expand linked CWs" feature for now.
pull/585/head
Karthik Balakrishnan 2023-05-20 12:32:40 +05:30 zatwierdzone przez GitHub
rodzic 568b87dadb
commit 68dc2dc9ed
Nie znaleziono w bazie danych klucza dla tego podpisu
ID klucza GPG: 4AEE18F83AFDEB23
1 zmienionych plików z 1 dodań i 2 usunięć

Wyświetl plik

@ -1,5 +1,4 @@
import datetime
import hashlib
import json
import mimetypes
import ssl
@ -436,7 +435,7 @@ class Post(StatorModel):
"""
if not self.summary:
return ""
return "summary-" + hashlib.md5(self.summary.encode("utf8")).hexdigest()
return "summary-{self.id}"
@property
def stats_with_defaults(self):