corrected call of function