Add page titles where needed

This commit is contained in:
Christine Dodrill 2015-02-06 16:33:34 -08:00
parent 1f94bb0246
commit dd5aeab2c3
2 changed files with 3 additions and 0 deletions

View File

@ -9,6 +9,7 @@ import assert_valid from require "lapis.validate"
class Email extends lapis.Application
[email: "/contact/email"]: respond_to {
GET: =>
@title = "Contact Me"
@csrf_token = csrf.generate_token @
return render: true

View File

@ -10,9 +10,11 @@ gh = require('github').new({access_token: os.getenv "GITHUB_TOKEN", httpclient_d
class Projects extends lapis.Application
[projects: "/projects"]: =>
@title = "Projects"
render: true
[readme: "/projects/:name"]: =>
@title = "Readme for #{@params.name}"
@ret, @err = oleg.get "readmes", @params.name
ngx.log ngx.NOTICE, "Got content from oleg, code #{@err}"