function getProperty(obj, prop) {
  if (obj == null) {
    return obj;
  }
  if (obj instanceof Map) {
    return obj.get(prop);
  }
  return obj[prop];
}
Simplified lodash.get to work around the annoying null quirk. See:
https://github.com/lodash/lodash/issues/3659
@api private