Error: invalid target for call. What to do: make sure that target satisfies type rules.