Fix getAttributeNS usages

As well described in #562, getAttributeNS in more and more browsers returns `null` if the attribute does not exist.

Sadly the externs coming with Closure Compiler define the return result to be `string`, and I found no way to redefine that to `?string`. So for now we just have to be aware of that and not completely rely on closure compiler.

I went through all usages of getAttributeNS and created fixes for all the cases where the returned value could be `null` with valid ODF documents, due to attributes being optional (besides the place for which there is a fix in #562). The other cases I ignored, due to currently unclear policy how to deal with invalid ODF documents.