Complexity refactor on #token method