Commit 0c9e1e5b authored by mark burdett's avatar mark burdett
Browse files

Issue #3299155 by mfb, foodslover: Document how developers can provide custom logic

parent 369711e7
Loading
Loading
Loading
Loading
+9 −0
Original line number Diff line number Diff line
@@ -58,6 +58,15 @@ duplicate uploaded files will be rejected site-wide. You may also leave this
setting off, and enable the dedupe validator in the field widget settings for a
particular file upload form.

IMPLEMENTING CUSTOM LOGIC
-------------------------

To implement custom logic not currently supported by built-in config options,
the `filehash` service class can be overridden by a custom class extending
`Drupal\filehash\FileHash` and implementing `Drupal\filehash\FileHashInterface`.
For example, your custom class might provide its own shouldHash() method to
determine whether or not a file should be hashed.

ENTITY QUERY SUPPORT
--------------------