fixed bug in wms_handler, typo was thowing exception which went unnoticed as it was wrapped in a vague try/except.