diff options
| author | sostler <sbostler@gmail.com> | 2010-01-15 13:23:30 -0500 |
|---|---|---|
| committer | sostler <sbostler@gmail.com> | 2010-01-15 13:23:30 -0500 |
| commit | 692e2d725f278708324fd2534007448ed03a150d (patch) | |
| tree | 86bc0b8c54fc90d912aebb8226a3a46f9964466b | |
| parent | ad22a53236804ee564f85b11cba4890e0ad9ae88 (diff) | |
removed set-user-attributes
| -rwxr-xr-x | src/site.clj | 13 |
1 files changed, 4 insertions, 9 deletions
diff --git a/src/site.clj b/src/site.clj index d387247..5868f94 100755 --- a/src/site.clj +++ b/src/site.clj @@ -194,17 +194,12 @@ ;; Templates -(defn set-user-attributes [st session] - (if (session :nick) - (.setAttribute st "user_nick" (session :nick)) - (.setAttribute st "isadmin" (session :is_admin)))) - (defn fetch-template [template-name session] (let [st (.getInstanceOf template-group template-name)] - (and st - (do - (set-user-attributes st session) - st)))) + (if (and st (session :nick)) + (do (.setAttribute st "user_nick" (session :nick)) + (.setAttribute st "isadmin" (session :is_admin)))) + st)) ;; Landing |
