updated bottle, fixed a header and referer bug