adapt to changed function interface