Revert "Hack to get around the broken cookie logic."

This reverts commit 22cb67cd709a1ed59ee37b1f1c4d8201ba3268c4.
Revert "api key is saved as a cookie now. This code's ugly."

This reverts commit 8cf66d61afd95b162161b243d866831248013347.