fix bad var sub and path to patch