code: @Override
      public Object[] getAttributeValues(String key) {
          if (userAttributes == null) {
              return null;
          }
  
          final List<Object> values = userAttributes.get(key);
          if (values != null) {
              return values.toArray();
          }
  
          return null;
      }
docs: Returns multiple attributes for a key. If only one value exists, it will be returned in an
  array of size one.
  
  @param key the attribute name
  @return the array of attribute values identified by the key