Fixed exception where setting int instead of long.