fix: branch and use correct function