Made some small changes in function calls