ni-c / heimcontrol.js

Home-Automation with node.js and Raspberry PI
MIT License
1.41k stars 297 forks source link

Don't crash on request without cookies (redirect to login instead) (fixes #76) #100

Closed tjanson closed 9 years ago

tjanson commented 9 years ago

When handling a request without cookies, i.e., with typeof req.headers.cookie === 'undefined', detect the problem and redirect to login rather than crashing. Fixes #76.