Commit Graph

14 Commits

Author SHA1 Message Date
Diogo Peralta Cordeiro 4d2131808a [FILE][TemporaryFile] Fix various issues now that we also have Symfony's file abstractions 2021-07-20 23:46:18 +01:00
Hugo Sales 041d19a22d [ATTACHMENTS] Don't store an attachment if it's a dupplicate, reuse it 2021-05-02 15:48:33 +00:00
Diogo Peralta Cordeiro 676210f76a [ATTACHMENTS] Follow URL redirects and don't duplicate attachments 2021-05-02 00:00:03 +01:00
Diogo Peralta Cordeiro 5a40d1f3e3 [Embed] Fix some bugs and change AttachmentEmbed::url to ::media_url 2021-05-01 23:58:49 +01:00
Diogo Peralta Cordeiro ced6e236ce [ATTACHMENTS][GSFile] Rename ValidateAndStore functions 2021-05-01 23:57:51 +01:00
Hugo Sales 650bfec699 [ATTACHMENTS] In sendFile, check that file exists or show a custom exception 2021-05-01 13:02:14 +00:00
Hugo Sales 93e1e4b7a9 [ENTITY] Add field size to attachments, used for quota calculations 2021-04-30 23:08:08 +01:00
Hugo Sales d49de9d35e [CORE] Typo in GSFile and slight Twig weirdness in base template 2021-04-28 20:16:59 +00:00
Hugo Sales 6da8cf7f14 [ATTACHMENTS] Add event 'AttachmentFileInfo' to allow a plugin to override the file displayed 2021-04-28 15:01:40 +00:00
Hugo Sales f388554166 [ATTACHMENTS][EVENT] Add onHashFile event, which can be used to deduplicate files
Currently, we simply hash the contents of the file with sha256, but in the future we can use something smarter,
which could find visual feature similarity between images
2021-04-27 20:53:59 +00:00
Hugo Sales c1db9bd0a3 [Posting] Extract and store URLs from note content. Introduce 'AttachmentStoreNew' event 2021-04-25 21:20:28 +00:00
Hugo Sales 5ec7717fa1 [ATTACHMENTS] Move thumbnail controller to core and cleanup 2021-04-19 13:22:50 +01:00
Diogo Peralta Cordeiro 2f137f8b44 [ATTACHMENTS] Even more further refactoring
Introduce Encoder plugins Instead of abstract upload and thumb modules

Ported attachment routes. In v3 thumbnail depends on existing attachment
so route updated accordingly.
2021-04-19 13:22:04 +01:00
Diogo Peralta Cordeiro 0f52638a80 [ATTACHMENTS] Further refactoring
Some key points:
- Components and Plugins shouldn't extend Module directly
- Avatars should be fetched via GSActor ID, not by nickname as that isn't unique
- Avatar now is a separate Component
- Common file utilities are now to be placed in Core\GSFile, this will
  handle storage and trigger validation
- Some bug fixes
2021-04-19 13:21:32 +01:00