we can only return a class if a targetDocument is defined