removed duplicated functions