Fixing check for a valid timestamp

Fixing implementation of isValidTimestamp to correctly validate for a valid timestamp, based on suggestions here: http://stackoverflow.com/questions/3377537/checking-if-a-string-contains-an-integer/3377560#3377560
Merge pull request #38 from jtbonaccorsi/master

Fixing check for a valid timestamp