Fixed typecasting issue for unusual strings

Stops numeric-like strings like '4:3' being cast as a number.