From 1f593f6bbc719da65b2fc96125f2f0cf89b05803 Mon Sep 17 00:00:00 2001
From: Slava Pestov <slava@slava-pestovs-macbook-pro.local>
Date: Thu, 11 Mar 2010 19:13:57 +1300
Subject: [PATCH] furnace.recaptcha: cleanups

---
 .../furnace/recaptcha/example/example.factor  |  2 +-
 basis/furnace/recaptcha/recaptcha-docs.factor |  2 +-
 basis/furnace/recaptcha/recaptcha.factor      | 28 +++++++++----------
 3 files changed, 16 insertions(+), 16 deletions(-)

diff --git a/basis/furnace/recaptcha/example/example.factor b/basis/furnace/recaptcha/example/example.factor
index 264be678ae..d453edb10e 100644
--- a/basis/furnace/recaptcha/example/example.factor
+++ b/basis/furnace/recaptcha/example/example.factor
@@ -9,7 +9,7 @@ IN: furnace.recaptcha.example
 
 TUPLE: recaptcha-app < dispatcher recaptcha ;
 
-: recaptcha-db ( -- obj ) "recaptcha-example" <sqlite-db> ;
+: recaptcha-db ( -- obj ) "resource:recaptcha-example" <sqlite-db> ;
 
 : <recaptcha-challenge> ( -- obj )
     <page-action>
diff --git a/basis/furnace/recaptcha/recaptcha-docs.factor b/basis/furnace/recaptcha/recaptcha-docs.factor
index 1349b5243d..0e901f8bb5 100644
--- a/basis/furnace/recaptcha/recaptcha-docs.factor
+++ b/basis/furnace/recaptcha/recaptcha-docs.factor
@@ -26,7 +26,7 @@ ARTICLE: "recaptcha-example" "Recaptcha example"
     { "Wrap the responder in a " { $link <recaptcha> } }
     { "Wrap the responder in a " { $link <conversations> } " if it is not already" }
     { "Ensure that there is a database connected, with the " { $link <alloy> } " word" }
-    { "Start a conversation to move values between requests" }
+    { "Start a conversation with " { $link begin-conversation } " to move values between requests" }
     { "Add a handler calling " { $link validate-recaptcha } " in the " { $slot "submit" } " of the " { $link page-action } }
     { "Pass the conversation from your submit action using " { $link <continue-conversation> } }
     { "Put the chloe tag " { $snippet "<recaptcha/>" } " inside a form tag in the template for your " { $link page-action } }
diff --git a/basis/furnace/recaptcha/recaptcha.factor b/basis/furnace/recaptcha/recaptcha.factor
index 99b223b8e3..020b5e472e 100644
--- a/basis/furnace/recaptcha/recaptcha.factor
+++ b/basis/furnace/recaptcha/recaptcha.factor
@@ -23,23 +23,23 @@ M: recaptcha call-responder*
 
 : (render-recaptcha) ( private-key -- xml )
     dup
-[XML <script type="text/javascript"
-   src=<->>
-</script>
+    [XML
+        <script type="text/javascript"
+           src=<->>
+        </script>
 
-<noscript>
-   <iframe src=<->
-       height="300" width="500" frameborder="0"></iframe><br/>
-   <textarea name="recaptcha_challenge_field" rows="3" cols="40">
-   </textarea>
-   <input type="hidden" name="recaptcha_response_field" 
-       value="manual_challenge"/>
-</noscript>
-XML] ;
+        <noscript>
+           <iframe src=<->
+               height="300" width="500" frameborder="0"></iframe><br/>
+           <textarea name="recaptcha_challenge_field" rows="3" cols="40">
+           </textarea>
+           <input type="hidden" name="recaptcha_response_field"
+               value="manual_challenge"/>
+        </noscript>
+    XML] ;
 
 : recaptcha-url ( secure? -- ? )
-    [ "https://api.recaptcha.net/challenge" ]
-    [ "http://api.recaptcha.net/challenge" ] if
+    "https://api.recaptcha.net/challenge" "http://api.recaptcha.net/challenge" ?
     recaptcha-error cget [ "?error=" glue ] when* >url ;
 
 : render-recaptcha ( -- xml )