Make dispatcher independent of type