fixes bug 1068743 - Thumbnail syntax error due to geometry being 'undefined'
pep8 cleanup