소스 검색

Limit short title lengths to 50 characters.

tags/v0.1^2
Ben Kurtovic 12 년 전
부모
커밋
bafc660846
1개의 변경된 파일4개의 추가작업 그리고 1개의 파일을 삭제
  1. +4
    -1
      bot/tasks/afc_statistics.py

+ 4
- 1
bot/tasks/afc_statistics.py 파일 보기

@@ -336,7 +336,10 @@ class Task(BaseTask):
return None, 0

def get_short_title(self, title):
return re.sub("Wikipedia(\s*talk)?\:Articles\sfor\screation\/", "", title)
short = re.sub("Wikipedia(\s*talk)?\:Articles\sfor\screation\/", "", title)
if len(short) > 50:
short = "".join((short[:47], "..."))
return short

def get_create(self, pageid):
query1 = "SELECT MIN(rev_id) FROM revision WHERE rev_page = ?"


불러오는 중...
취소
저장