Rework XML parser: part 1

This is the first step of the parser refactoring: here we change
	the configuration, next step will change data saving.
This commit is contained in:
nemunaire 2015-10-27 18:03:28 +01:00
commit c560e13f24
18 changed files with 370 additions and 122 deletions

View file

@ -16,7 +16,7 @@ from more import Response
URL_API = "http://open.mapquestapi.com/geocoding/v1/address?key=%s&location=%%s"
def load(context):
if not context.config or not context.config.hasAttribute("apikey"):
if not context.config or "apikey" not in context.config:
raise ImportError("You need a MapQuest API key in order to use this "
"module. Add it to the module configuration file:\n"
"<module name=\"mapquest\" key=\"XXXXXXXXXXXXXXXX\" "