Fixed some bugs, setting it up again for parsing