removed deprecated code
format code