Skip to content

Instantly share code, notes, and snippets.

@timuruski
Created January 4, 2012 19:26
Show Gist options
  • Select an option

  • Save timuruski/fddfdf9ab0772807e1a6 to your computer and use it in GitHub Desktop.

Select an option

Save timuruski/fddfdf9ab0772807e1a6 to your computer and use it in GitHub Desktop.
// Operational
{
"operational": true,
"message": null
}
// Failing
{
"operational": false,
"message": "We'll be right back."
}
MESSAGE = "We'll be right back"
HEADERS = { 'Content-Type'=>'application/json' }
BODY = <<-EOS
{ "operational": #{MESSAGE.empty?},
"message": "#{MESSAGE}" }
EOS
run lambda { |env| [200, HEADERS, [BODY]] }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment