Similarly, the condition here could be simplified to `elem.disabled === true || elem.disabled === false && elem.isDisabled === true` (or a more compressible equivalent).