changed type checking to use .get()
changed type checking to use .get()

tiddlyweb.type is not always present, so using .get() instead.

Fixes https://github.com/TiddlySpace/tiddlyspace/issues#issue/507

TiddlySpace/tiddlyspace,TiddlySpace/tiddlyspace,TiddlySpace/tiddlyspace,FND/tiddlyspace,FND/tiddlyspace,FND/tiddlyspace