fixes; token generation working