Fixed bug in repair on tokens.
Merge branch 'test' into dev