got parser working for all cases, added error checking