Added base path to store cookie

* Added base path to store cookie
* Removed unused variable