Fix method detection