refactor: made functions private; removed unnecessary init