Custom Field can be applied to selected projects, but might not all projects. The issues could be the parent/child of the other issues in different projects.
If ProjectA/B/C are assigned a custom field, for example, MyField, but ProjectX does not (which could be new created or just add one issue as child of issue in ProjectA). Then the workflow scripts might get runtime error while it would trying to go through all child issues to update the value of MyField.
I have tried project.fields.contains("MyField"), or for each fld in project.fields (but there is no fld.name or fld.getPresentation methods), also message(fld) will show something like "78-148", or "78-149", etc.
None of above works.
So how to check if a project contains a custom field ?