Commit Graph

127 Commits

Author SHA1 Message Date
Hugo Sales b82658e345 [SECURITY][DB] Make user register 'atomic', by using a single transaction for inserting all objects, to avoid partial inserts 2021-04-23 12:54:25 +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
Hugo Sales f6dea6e162 [DB] Fix bug in custom criteria format wrangling 2021-04-16 20:28:39 +01:00
Hugo Sales 2f65311ae6 [DB] Allow DQL queries with table name rather than entity 2021-04-16 20:28:39 +01:00
Hugo Sales cadd48922d [CORE] Add functionality to App\Core\Controller to get and validate GET parameters 2021-04-16 20:28:39 +01:00
Hugo Sales d6414e51a2 [CORE] Rename NoteScope to VisibilityScope, as it will be used for attachment visbility too 2021-04-16 20:28:39 +01:00
Hugo Sales 1fda65bc3d [DB] Add table map which allows using table names rather than entities in Doctrine operations 2021-04-16 20:28:39 +01:00
Hugo Sales 8fc2a83e3c [CONFIG][TWIG] Move twig config to php code to add support for placing templates in modules (plugins and components) 2021-04-16 20:21:54 +01:00
Hugo Sales 0802f7a9e3 [TWIG] Add way to launch events from TWIG, capture service and add way to render from a string 2021-04-16 20:21:54 +01:00
Hugo Sales c5b26bcffb [FAVOURITE] Temporary commit to fix exception in timeline 2021-04-16 20:21:54 +01:00
Diogo Peralta Cordeiro a1cac40f6a [MODULES] Introduce the concept of abstract modules to V3
Introduce placeholder for abstract upload and thumb modules
Temporarily supress some bugs
2021-04-16 20:21:54 +01:00
Hugo Sales d0fd0e6c6c [DB] Remove unique constraint from GSActor.nickname and fix register and related functionality 2021-04-14 15:37:24 +00:00
Hugo Sales 637c25d5fe [WEB] Fix translations and small inconsistency when opening on web 2021-04-14 15:37:24 +00:00
Hugo Sales 051720a686 [TESTS] Add tests to all relevant methods under App\Util and fix errors that popup 2021-04-14 15:37:24 +00:00
Hugo Sales cafd9a39a0 [TESTS] Add tests of Common and fix small oddities that pop up 2021-04-14 15:37:24 +00:00
Hugo Sales b855dd00ac [LOG] Only try to log if setup, so logs can be disabled, in tests, for instance 2021-04-14 15:37:24 +00:00
Hugo Sales d082f4249c CACHE] Fix cache implementation with the help of tests and remove premature optimization for non-redis list caching
This complicated the code significantly and likely didn't help that much, if at all. The recommended setup is using Redis, anyway, which is plenty optimized
2021-04-14 15:37:24 +00:00
Hugo Sales ffaf5da984 [TESTS] Fix unkept unit tests 2021-04-14 15:37:23 +00:00
Daniel 7a925cd9a6 [Poll] Added modified param for Poll/Poll response, added PollTest 2021-04-14 15:37:23 +00:00
Hugo Sales 256169a3c4 [GIT] Change my email to the new one in all files and bump copyright year 2021-04-14 15:37:23 +00:00
Hugo Sales 0d2cf6eaa6 [DB] Merge definition of SchemaDefDriver with SchemaDefPass for clarity 2021-04-14 15:37:23 +00:00
Hugo Sales 5cced1c9ed [DOCUMENTATION][REFACTOR] Add documentation to all flagged function and do some small cleanup 2021-04-14 15:37:23 +00:00
Hugo Sales fdaa89e3c9 [EVENT] Rename event names to camel case to make finding handlers easier 2021-04-14 15:37:23 +00:00
Hugo Sales 4b4da170f2 [CONFIG][CACHE] Move cache configuration from environment variables to the configuration file 2021-04-14 15:37:23 +00:00
Hugo Sales 06e92344cc [CONFIG] Various fixes to use new configuration format 2021-04-14 15:37:23 +00:00
Hugo Sales 02c7bdf4f0 [CONFIG][DB] Remove config from the database, put it in yaml, so it can be baked into the container 2021-04-14 15:37:22 +00:00
Hugo Sales 8547c54103 [CORE] Add missing use statement in module base class 2021-04-14 15:37:22 +00:00
Hugo Sales abc32ecc0e [NoteAction] Refactor duplicated code out to base class 2021-04-14 15:37:22 +00:00
Hugo Sales 7e7bfd1958 [EXCEPTION] Make findOne return NotFoundException 2021-04-14 15:37:22 +00:00
Hugo Sales e0672e559a [MODULES] Fix module manager dev-mode rebuild 2021-04-14 15:37:22 +00:00
Hugo Sales 9ae31501cc [Controller] Fix exception handler to recurse on the exception's previous (in some contexts, RedirectException gets wrapped) 2021-04-14 15:37:22 +00:00
Hugo Sales 1330c96681 [UTIL] Update bitmap base class, making using easier 2021-04-14 15:37:22 +00:00
Hugo Sales 34fab45b6b [MODULE][DB] Added support for loading entity definitions from modules 2021-04-14 15:37:22 +00:00
Hugo Sales 749bec5d52 [EXCEPTION][UI][UX] Add RedirectException, which can be thrown anywhere to redirect somewhere, and an exception handler 2021-04-14 15:37:22 +00:00
Hugo Sales d862457623 [DB][DEFAULTS] Change attachment storage location from uploads to attachments 2021-04-14 15:37:22 +00:00
rainydaysavings af3ed18d48 [UI][TWIG] Fixing note actions placement and size, more descriptive rules 2021-04-14 15:37:22 +00:00
Hugo Sales 109b17b1f9 [FORM] Add names to forms 2021-04-14 15:37:22 +00:00
Hugo Sales 7b467091d6 [DB] Add wrapper for making native queries 2021-04-14 15:37:22 +00:00
Hugo Sales 75bc71f473 [DB] Add helper for removing entities 2021-04-14 15:37:22 +00:00
Hugo Sales 29f30a6932 [DB] Add support for calling methods with FQCN 2021-04-14 15:37:22 +00:00
Hugo Sales e13e763d5c [NOTE][UI] Add note replying and UI displaying 2021-04-14 15:37:22 +00:00
Hugo Sales c0caf520b8 [CACHE] Fix bug in list caching 2021-04-14 15:37:22 +00:00
Hugo Sales 9a0c64c3d1 [DEPENDENCY] Add tgalopin/html-sanitizer-bundle and transitively tgalopin/html-sanitizer 2021-04-14 15:37:22 +00:00
Hugo Sales b3c5fe9e96 [CONTROLLER] Stop propagation of kernel.controller so notices aren't posted 5 times. Not sure why it happens otherwise 2021-04-14 15:37:22 +00:00
Hugo Sales 8ca49478ab [WRAPPER][HTTPClient] Static wrapper around Symfony's HTTP Client 2021-04-14 15:37:22 +00:00
Hugo Sales 86bd1dbbbf [DB][DEFAULTS] Add avatar/default 2021-04-14 15:37:22 +00:00
Hugo Sales fe50909549 [DB] Add 'dql' method to wrap 'createQuery' and replace 'Gsactor' with 'GSActor' 2021-04-14 15:37:22 +00:00
Hugo Sales 036b4480f3 [MEDIA] Move avatar fetching and adding to ouput to media component 2021-04-14 15:37:22 +00:00