Added check for null of maps

resolves #252