Skip to content

Commit

Permalink
fix phabricator ticket #T173822, 'CatGraph on commons missing subcate…
Browse files Browse the repository at this point in the history
…gories'
  • Loading branch information
Johannes Kroll committed Sep 18, 2017
1 parent 41f70bf commit 00a81bb
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion catgraph-jsonp.fcgi
Expand Up @@ -42,7 +42,7 @@ def category_title_to_pageid(wiki, title):
cursor= conn.cursor()
cursor.execute("use %s" % (wiki if wiki=='gptest1wiki' else wiki + '_p'))
title_underscores= title.encode('utf-8').replace(' ', '_')
for t in [ [title_underscores.capitalize(), "page_title"], [title_underscores, "page_title"], [title_underscores.lower(), "lower(page_title)"] ]:
for t in [ [title_underscores, "page_title"], [title_underscores.capitalize(), "page_title"], [title_underscores.lower(), "lower(page_title)"] ]:
cursor.execute( "select page_id from page where " + t[1] + "=%s and page_namespace=14", (t[0]) )
res= cursor.fetchall()
if len(res):
Expand Down

0 comments on commit 00a81bb

Please sign in to comment.