code: public static @Nullable FileBinaryResource createOrNull(File file) {
      return (file != null) ? new FileBinaryResource(file) : null;
    }
docs: /*
  Factory method to create a wrapping BinaryResource without explicitly taking care of null.
  If the supplied file is null, instead of BinaryResource, null is returned.