Small bug fixes, still trying to fix parsing