fix synatax error in formatData