Professor @damithc
I have changed back to using lower level function and corrected the typo