Fixed a bug with tokens