Skip to content

Commit

Permalink
Only replace single instance of 'Handler' when constructing route name
Browse files Browse the repository at this point in the history
  • Loading branch information
hfaran committed Dec 21, 2013
1 parent 98b6f8d commit a6f0f4b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tornado_json/routes.py
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ def get_module_routes(
# URL, requesthandler tuple
(
"/{}/{}".format("/".join(module_name.split(".")[1:]),
k.lower().replace('handler', '') if
k.lower().replace('handler', '', 1) if
k.lower().endswith('handler') else k.lower()),
getattr(module, k)
)
Expand Down

0 comments on commit a6f0f4b

Please sign in to comment.