Fix #1 bug and added parse cookies

Yes, sorry)