Added more changes to the method.