initSync
organized code