Commit Graph

77 Commits

Author SHA1 Message Date
Hugo Sales 483983790a
[CORE][Router] Rename \App\Core\Router\Router to \App\Core\Router and merge \App\Core\Router\RouteLoader with \App\Core\Router 2022-03-28 20:59:15 +01:00
Diogo Peralta Cordeiro be33c20614
[PLUGIN][ActivityPub] Improve flexibility of Type layer, accomodate more elaborate understanding of Group Announces after FEP-2100 development 2022-03-28 20:58:48 +01:00
Hugo Sales 9a9eed1457
[CORE][Router][Form] Add Router::sanitizeLocalURL and use it in Form::forceRedirect 2022-03-09 20:51:42 +00:00
Diogo Peralta Cordeiro 893d299e29
[UTIL][Common] Respect detect language setting
Minor bug fix
2022-03-09 14:24:50 +00:00
Diogo Peralta Cordeiro e67ed58286
[TESTS] Temporarily Disable Controller/AdminTest: It seems we are repeating values arbitrarily - specially in plugins, and the generated file is just nonsense overall really, wrong sections and stuff 2022-03-09 01:40:34 +00:00
Hugo Sales 9a0c74cb0c
[CORE][SECURITY] Replicate 'next' form submission feature on login form 2022-03-07 15:26:27 +00:00
Hugo Sales 7c9b01c516
[UTIL][Common] Add Common::getRequest 2022-03-04 15:09:39 +00:00
Hugo Sales da6d3bd351
[COMPONENT][Collection] Use current locale 2022-01-09 12:29:34 +00:00
Diogo Peralta Cordeiro 0d1ab2c9cf
[SECURITY][Register] New users should have their current browser language set as first language preference 2022-01-05 04:19:35 +00:00
Diogo Peralta Cordeiro 5a0bbfc795
[UTIL][Common][I18N] Use actor's preferred language for _m and utility to retrieve current language even when no actor is logged in 2022-01-05 01:29:26 +00:00
Hugo Sales b1262919da
[TOOLS] Fix (most) issues found by PHPStan 2021-11-25 23:08:30 +00:00
Hugo Sales b4ce77320e
[TESTS] Fix remaining tests, back to 100% passed. Some minor semantic changes 2021-11-20 21:33:25 +00:00
Hugo Sales eab6de3609
[TESTS][Security] Fix SecurityTest. Remove nickname normalization on register (a plugin can handle that). Move from filter_var(FILTER_VALIDATE_EMAIL) as it does not support dotless domains 2021-11-15 19:25:50 +00:00
Hugo Sales 839fa070c7
[CORE][Posting] Default Posting language to site language, if the user hasn't selected one 2021-11-02 11:14:59 +00:00
Diogo Peralta Cordeiro 712d1739e4
[UTIL][Formatting] Make local mentions great again 2021-11-01 12:16:29 +00:00
Eliseu Amaro 8038fdbce9
[UTIL][Common] Added Common::getUploadLimit().
[COMPONENT][Posting] Update Posting to warn the user of submtting attachments too large.
2021-10-27 04:19:32 +01:00
Hugo Sales 9109c61af5
[TOOLS][CS-FIXER] Run new PHP CS Fixer config. Notably, adds strict_types 2021-10-27 04:19:28 +01:00
Diogo Peralta Cordeiro 071b769997
[CORE][Util][Common] Correct behaviour for absense of value 2021-10-18 13:22:45 +01:00
Diogo Peralta Cordeiro 67d62cf37b
[TWIG] Remove kludge event TwigPopulateVars 2021-09-18 07:27:35 +01:00
Diogo Peralta Cordeiro 941cbe6599
[Actor] Refactor GSActor into Actor 2021-09-18 05:12:17 +01:00
Hugo Sales 15a2a69274
[ROUTER] Add option `is_system_path`, to allow specifying that a route, such as `gsactor_view_nickname` should not be considered a system path, when checking for the collision of nicknames 2021-09-18 05:12:05 +01:00
Hugo Sales b74d944ae3
[TOOLS][PHPStan] Raise PHPStan level to 3 and fix new errors 2021-09-14 13:13:45 +01:00
Hugo Sales cbbef90752
[UTIL][CONFIG] Ensure `setConfig` uses a `locals` key 2021-09-14 13:13:41 +01:00
Hugo Sales 141f919ca7
[CONFIG][TESTS] Fix error found by AdminPanel test 2021-09-14 13:13:36 +01:00
Hugo Sales c71a4b06ef
[CONFIG] Make it possible to write module configuration in a config.{php,yml,yaml,xml} file and set each value as properties in the module object 2021-09-14 13:13:36 +01:00
Diogo Peralta Cordeiro 63cbf4052f
[UTIL] Common::config wasn't a proper port from v2, it has to accept one argument only as well 2021-09-14 13:13:25 +01:00
Hugo Sales 687b2e2bc7
[UTIL] Add utility to flatten the result of note queries 2021-09-14 13:13:02 +01:00
Hugo Sales 86400ce815
[UTIL] Provide static access to current request and utilities in Common 2021-09-14 13:13:02 +01:00
Hugo Sales abda73b8e3
[TESTS] Raise App\Util\Common test coverage to 100% 2021-09-14 13:12:58 +01:00
Hugo Sales 60a9085e56
[FORMATTING] Add utilities to remove affixes from strings 2021-09-14 13:12:51 +01:00
Hugo Sales 94edad43d9
[UTIL] Add method to validate url 2021-09-14 13:12:23 +01:00
Diogo Peralta Cordeiro 0eaccc32fe
[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-09-14 13:11:51 +01:00
Hugo Sales e2e561e663
[DB][FKEY] Temporarily disable foreign key mapping, as there seems to be a bug in doctrine, which is under investigation 2021-09-14 13:10:23 +01:00
Hugo Sales 78548365da
[WEB] Fix translations and small inconsistency when opening on web 2021-09-14 13:10:23 +01:00
Hugo Sales 8b5bd40421
[TESTS] Add tests to all relevant methods under App\Util and fix errors that popup 2021-09-14 13:10:23 +01:00
Hugo Sales dc2a453e94
[TESTS] Add tests of Common and fix small oddities that pop up 2021-09-14 13:10:22 +01:00
Hugo Sales b387ea9aa0
[TESTS] Fix error when testing cold redis cache 2021-09-14 13:10:22 +01:00
João Brandão 5516a77b33
[UI][TIMELINES] Refactored query for public stream 2021-09-14 13:10:19 +01:00
Daniel c0d363e317
[Poll] Restructured templates, added misssing poll related css 2021-09-14 13:10:13 +01:00
Daniel 7a299162e1
[Poll] Polls now have an associated note, poll templates, start_show_styles event, started css 2021-09-14 13:10:13 +01:00
Daniel ffb4b9df23
[Poll] Added modified param for Poll/Poll response, added PollTest 2021-09-14 13:10:12 +01:00
Hugo Sales 460712e15e
[GIT] Change my email to the new one in all files and bump copyright year 2021-09-14 13:06:56 +01:00
Hugo Sales e8feb2ae84
[DOCUMENTATION][REFACTOR] Add documentation to all flagged function and do some small cleanup 2021-09-14 13:06:55 +01:00
Hugo Sales e949dd654a
[CONFIG] Various fixes to use new configuration format 2021-09-14 13:06:54 +01:00
Hugo Sales dd40255c4a
[CONFIG][DB] Remove config from the database, put it in yaml, so it can be baked into the container 2021-09-14 13:06:53 +01:00
Hugo Sales d95c22cb3e
[EXCEPTION] Fix exceptions not being translated 2021-09-14 13:06:48 +01:00
Hugo Sales 0b50905ac8
[NOTE][UI] Add note replying and UI displaying 2021-09-14 13:06:45 +01:00
Hugo Sales 8506a0248d
[UTIL][Common] Fix import 2021-09-14 13:05:54 +01:00
Hugo Sales a2269f5745
[UTIL][Common] Implement 'isSystemPath' 2021-09-14 13:05:54 +01:00
Hugo Sales 8716d700a6
[CORE][DB] Fix uses of db tables after previous restructure 2021-09-14 13:05:53 +01:00