Added callSync function