still converting js to OO format