Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Extract captcha.net client/secret to config

  • Loading branch information...
commit 4c4c1264f2923377a49ba8c9739ba66c1f0edd52 1 parent 0758e9b
@nbarrientos authored
Showing with 5 additions and 2 deletions.
  1. +2 −0  app.py
  2. +3 −2 tools.py
View
2  app.py
@@ -22,6 +22,8 @@
define("desc_max_len", default=150, help="FIXME", type=int)
define("max_tokens_per_ip", default=3, help="FIXME", type=int)
define("environment", default="development", help="FIXME", type=str)
+define("captcha_net_client", default="demo", help="FIXME", type=str)
+define("captcha_net_secret", default="secret", help="FIXME", type=str)
class Application(tornado.web.Application):
def __init__(self):
View
5 tools.py
@@ -41,8 +41,9 @@ def format_filesize(size):
return (size, units[units_index])
def obtain_captcha_service():
- return CaptchasDotNet(client='demo',
- secret='secret')
+ settings = { "client": options.captcha_net_client,
+ "secret": options.captcha_net_secret }
+ return CaptchasDotNet(**settings)
def devel_env():
ret = False
Please sign in to comment.
Something went wrong with that request. Please try again.