loomio/loomio — pull request #1314 by gdpelican (2014-02-25 04:53:59+00:00)
Title: Check for sane ENV before loading app (not ready)

Hey @robguthrie, what do you think about something like this for ensuring a valid ENV before loading the app?

This way we can just do `ENV.fetch('REQUIRED_KEY')` with confidence, but if somebody tries to load up the app without having a key set, they get a nice instructive error.

Could even expand to set up the ENV with default keys if they're not set explicitly, so instead of having to do `ENV.fetch('OPTIONAL_KEY', 'default')` everywhere, could just set them on app startup and be able to just call `ENV.fetch('OPTIONAL_KEY') `