fix variable parsing