verify DOM.enable() exists before calling it
fix condition
Merge pull request #10195 from adobe/randy/issue-10191

Verify DOM.enable() exists before calling it