mattdrayer/api-session-check-existing: Skip login if already logged in

@chrisndodge @martynjames -- updated the POST /sessions workflow to skip the login() routine if the user is already logged in -- had to move some code around and added some helper functions along the way.  Let me know what you think.

@fredsmith, FYI on this change -- we'll need to figure out how to work it into the deployment stream -- if we set up a release candidate branch we could cherry-pick the commit into it -- or I suppose we could close this PR and resubmit to the RC, then merge back to master -- however we want to manage the code is fine w/ me
We should probably think through what it might mean to share a session between potentially two different browsers. I'm wondering if logging out of one browser will cause the other browser to have an invalid session.