call correct method