Cleaned up, working on implementing cookie retrieval in a better manner than previous way.