Formula encoding fix