code: public void setArrayIfNotEmpty(@NotNull final String key, @Nullable final List<String> value) {
          if (null != value && !value.isEmpty()) {
              setString(key, new Gson().toJson(value));
          }
      }
docs: Sets a property value only if the array value is not null and not empty.
  
  @param key the key for the property
  @param value the value for the property