We have same function in another place.
need refactoring