refacted the code about status info metadata