add tern and correct sparkup