replaced a misplace variable